                     // TODO: do we have everything we need from the remote game slot here? ie. the restofcards and stuff?
                     self.gameSlot = self.getLastGameSlot(allGameSlots: allGameSlots)
 
-                    for i in 0...1 {
+                    for i in 0...(self.maxNumPlayers - 1) {
 
                         let playerReference = referenceToAllGameSlots.child("list").child(String(self.slotKey)).child("player" + String(i))
 

class GamePlay {

    var numPlayers:Int = 0
    var cards:[Card] = []
    var shuffledCards:[Card] =  []
    var slotIncrement:Int = 0

                    }

                    referenceToAllGameSlots.child("lastSlot").setValue(["value": self.slotKey])
                    self.setUpHandlerForRemotePlayerEvents()

                }
        })
