From: Kyle Date: Thu, 15 Apr 2010 01:06:50 +0000 (+0000) Subject: Allowed Game to start with less than 4 players. X-Git-Url: https://git.brokenzipper.com/gitweb?a=commitdiff_plain;h=b5f040f12134302d4b62542877e7260e079348d6;p=chaz%2Fcarfire Allowed Game to start with less than 4 players. git-svn-id: https://bd85.net/svn/cs3505_group@76 92bb83a3-7c8f-8a45-bc97-515c4e399668 --- diff --git a/CarFire/CarFire/CarFire/ScreenManager.cs b/CarFire/CarFire/CarFire/ScreenManager.cs index 4998eac..39d95dd 100644 --- a/CarFire/CarFire/CarFire/ScreenManager.cs +++ b/CarFire/CarFire/CarFire/ScreenManager.cs @@ -365,7 +365,7 @@ namespace CarFire } //allows host to start the game when all players are ready, change count below to different number for testing with less then 4 players - if (allReady && players.Count == 4 && localPlayer == players[0]) + if (allReady && players.Count <= 1 && localPlayer == players[0]) { if (currentKeyboardState.IsKeyDown(Keys.B) && previousKeyboardState.IsKeyUp(Keys.B)) { @@ -441,7 +441,7 @@ namespace CarFire case lobbyState.Connected: DrawPlayerList(spriteBatch); DrawChatInfo(spriteBatch); - if(allReady && players.Count == 2 && localPlayer == players[0]) + if(allReady && players.Count <= 4 && localPlayer == players[0]) spriteBatch.DrawString(menuFont, "Press B to begin game!", new Vector2(MaxX / 2, MaxY / 2), Color.White, 0f, zero, .7f, SpriteEffects.None, 0.5f); else if(allReady) spriteBatch.DrawString(menuFont, "The game will begin soon.", new Vector2(MaxX / 2, MaxY / 2), Color.White, 0f, zero, .7f, SpriteEffects.None, 0.5f);