]> Dogcows Code - chaz/carfire/commitdiff
edited join game screen
authorbrady <brady@92bb83a3-7c8f-8a45-bc97-515c4e399668>
Thu, 18 Mar 2010 07:17:45 +0000 (07:17 +0000)
committerbrady <brady@92bb83a3-7c8f-8a45-bc97-515c4e399668>
Thu, 18 Mar 2010 07:17:45 +0000 (07:17 +0000)
git-svn-id: https://bd85.net/svn/cs3505_group@7 92bb83a3-7c8f-8a45-bc97-515c4e399668

Project06/lobbyTest/lobbyTest/Content/Content.contentproj
Project06/lobbyTest/lobbyTest/Content/selectGameScreen.png [new file with mode: 0644]
Project06/lobbyTest/lobbyTest/LobbyGUI.cs

index 3c293d9aafed838923b0bf03b0f3c51dce154584..6305bbe9c4fdc2240180418f2a2adc4ca53c6ba7 100644 (file)
       <Processor>FontDescriptionProcessor</Processor>\r
     </Compile>\r
   </ItemGroup>\r
+  <ItemGroup>\r
+    <Compile Include="selectGameScreen.png">\r
+      <Name>selectGameScreen</Name>\r
+      <Importer>TextureImporter</Importer>\r
+      <Processor>TextureProcessor</Processor>\r
+    </Compile>\r
+  </ItemGroup>\r
   <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\v3.0\Microsoft.Xna.GameStudio.ContentPipeline.targets" />\r
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \r
        Other similar extension points exist, see Microsoft.Common.targets.\r
diff --git a/Project06/lobbyTest/lobbyTest/Content/selectGameScreen.png b/Project06/lobbyTest/lobbyTest/Content/selectGameScreen.png
new file mode 100644 (file)
index 0000000..af04c0c
Binary files /dev/null and b/Project06/lobbyTest/lobbyTest/Content/selectGameScreen.png differ
index b1205672cb48b962663afdfee0e15e05b2a85b2e..046fa7859130f21f4ccadc48dabbe1c58d1796ef 100644 (file)
@@ -14,6 +14,7 @@ namespace lobbyTest
         Texture2D background;\r
         Texture2D spotLight;\r
         Texture2D cs;\r
+        Texture2D selectGameScreen;\r
 \r
         Vector2 backgroundPos;\r
         Vector2 spotLightPos;\r
@@ -35,6 +36,9 @@ namespace lobbyTest
         Vector2 findGamePos;\r
         string findGameText;\r
 \r
+        Vector2 returnToMainPos;\r
+        string returnToMainText;\r
+\r
         KeyboardState previousKeyboardState;\r
         KeyboardState currentKeyboardState;\r
 \r
@@ -58,6 +62,7 @@ namespace lobbyTest
             background = contentManager.Load<Texture2D>("background");\r
             spotLight = contentManager.Load<Texture2D>("spotlight");\r
             cs = contentManager.Load<Texture2D>("cs");\r
+            selectGameScreen = contentManager.Load<Texture2D>("selectGameScreen");\r
             backgroundPos = new Vector2(0f, 0f);\r
             spotLightPos = new Vector2(100f, graphics.GraphicsDevice.Viewport.Height - 98);\r
             spotLightCenter = new Vector2(800f, 800f);\r
@@ -79,6 +84,9 @@ namespace lobbyTest
 \r
             findGamePos = new Vector2(100f, (MaxY / 3) + 60);\r
             findGameText = "Find Game";\r
+\r
+            returnToMainPos = new Vector2(MaxX / 2, MaxY - 120);\r
+            returnToMainText = "press [ X ] to return to main menu";\r
         }\r
 \r
         public void UnloadContent()\r
@@ -98,14 +106,14 @@ namespace lobbyTest
                     {\r
                         if (currentKeyboardState.IsKeyDown(Keys.Enter) && previousKeyboardState.IsKeyUp(Keys.Enter))\r
                             currentState = lobbyState.CreateGame;\r
-                        if (currentKeyboardState.IsKeyDown(Keys.Down) || currentKeyboardState.IsKeyDown(Keys.Up))\r
+                        if (currentKeyboardState.IsKeyDown(Keys.Down))\r
                             selected = findGameText;\r
                     }\r
                     else\r
                     {\r
                         if (currentKeyboardState.IsKeyDown(Keys.Enter) && previousKeyboardState.IsKeyUp(Keys.Enter))\r
                             currentState = lobbyState.FindGame;\r
-                        if (currentKeyboardState.IsKeyDown(Keys.Down) || currentKeyboardState.IsKeyDown(Keys.Up))\r
+                        if (currentKeyboardState.IsKeyDown(Keys.Up))\r
                             selected = createGameText;\r
                     }\r
                     break;\r
@@ -113,6 +121,8 @@ namespace lobbyTest
 \r
                     break;\r
                 case lobbyState.FindGame:\r
+                    if (currentKeyboardState.IsKeyDown(Keys.X) && previousKeyboardState.IsKeyUp(Keys.X))\r
+                        currentState = lobbyState.Welcome;\r
 \r
                     break;\r
                 case lobbyState.Connected:\r
@@ -145,11 +155,15 @@ namespace lobbyTest
                     else\r
                         spriteBatch.DrawString(menuFont, findGameText, findGamePos, Color.Gray, 0, zero, 1f, SpriteEffects.None, 0.5f);\r
                     break;\r
+                \r
                 case lobbyState.CreateGame:\r
                     \r
                     break;\r
                 case lobbyState.FindGame:\r
-                    \r
+                    spriteBatch.Draw(selectGameScreen, backgroundPos, null, Color.White, 0, zero, 0.5f, SpriteEffects.None, 0);\r
+                    //spriteBatch.DrawString(menuFont, "Select Game", new Vector2(100, 100), Color.Gray, 0, zero, 1f, SpriteEffects.None, 0.5f);\r
+\r
+                    //spriteBatch.DrawString(menuFont, returnToMainText, returnToMainPos, Color.Gray, 0, new Vector2(180 , 0), .6f, SpriteEffects.None, 0.5f);\r
                     break;\r
                 case lobbyState.Connected:\r
                     \r
This page took 0.025693 seconds and 4 git commands to generate.