Advertisement
Guest User

Control TextBox con "autoexplicacion"

a guest
Oct 31st, 2010
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VB.NET 2.96 KB | None | 0 0
  1. Imports System
  2. Imports System.Collections.Generic
  3. Imports System.Linq
  4.  
  5. Imports Microsoft.Xna.Framework
  6. Imports Microsoft.Xna.Framework.Audio
  7. Imports Microsoft.Xna.Framework.Content
  8. Imports Microsoft.Xna.Framework.GamerServices
  9. Imports Microsoft.Xna.Framework.Graphics
  10. Imports Microsoft.Xna.Framework.Input
  11. Imports Microsoft.Xna.Framework.Media
  12. Imports Microsoft.Xna.Framework.Net
  13. Imports Microsoft.Xna.Framework.Storage
  14.  
  15. ''' <summary>
  16. ''' This is the main type for your game
  17. ''' </summary>
  18. Public Class CBaseClient ' You could also call this class "Game1" I suppose
  19.     Inherits Microsoft.Xna.Framework.Game
  20.  
  21.     Dim graphics As GraphicsDeviceManager
  22.     Dim spriteBatch As SpriteBatch
  23.  
  24.     Public Sub New()
  25.         graphics = New GraphicsDeviceManager(Me)
  26.         Content.RootDirectory = "Content"
  27.     End Sub
  28.  
  29.     ''' <summary>
  30.     ''' Allows the game to perform any initialization it needs to before starting to run.
  31.     ''' This is where it can query for any required services and load any non-graphic
  32.     ''' related content.  Calling base.Initialize will enumerate through any components
  33.     ''' and initialize them as well.
  34.     ''' </summary>
  35.     Protected Overrides Sub Initialize()
  36.  
  37.         ' TODO: Add your initialization logic here
  38.  
  39.         MyBase.Initialize()
  40.     End Sub
  41.  
  42.     ''' <summary>
  43.     ''' LoadContent will be called once per game and is the place to load
  44.     ''' all of your content.
  45.     ''' </summary>
  46.     Protected Overrides Sub LoadContent()
  47.         MyBase.LoadContent()
  48.         ' Create a new SpriteBatch, which can be used to draw textures.
  49.         spriteBatch = New SpriteBatch(GraphicsDevice)
  50.  
  51.         ' TODO: use this.Content to load your game content here
  52.     End Sub
  53.  
  54.     ''' <summary>
  55.     ''' UnloadContent will be called once per game and is the place to unload
  56.     ''' all content.
  57.     ''' </summary>
  58.     Protected Overrides Sub UnloadContent()
  59.         MyBase.UnloadContent()
  60.  
  61.         ' TODO: Unload any non ContentManager content here
  62.     End Sub
  63.  
  64.     ''' <summary>
  65.     ''' Allows the game to run logic such as updating the world,
  66.     ''' checking for collisions, gathering input, and playing audio.
  67.     ''' </summary>
  68.     ''' <param name="gameTime">Game time snapshot</param>
  69.     Protected Overrides Sub Update(ByVal gameTime As GameTime)
  70.         ' Allows the game to exit
  71.         If Keyboard.GetState().IsKeyDown(Keys.Escape) Then Me.Exit()
  72.  
  73.         ' TODO: Add your update logic here
  74.  
  75.         MyBase.Update(gameTime)
  76.     End Sub
  77.  
  78.     ''' <summary>
  79.     ''' This is called when the game should draw itself.
  80.     ''' </summary>
  81.     ''' <param name="gameTime">Game time snapshot</param>
  82.     Protected Overrides Sub Draw(ByVal gameTime As Microsoft.Xna.Framework.GameTime)
  83.         GraphicsDevice.Clear(Color.CornflowerBlue)
  84.  
  85.         spriteBatch.Begin(SpriteBlendMode.AlphaBlend)
  86.  
  87.         ' TODO: Add your drawing code here
  88.  
  89.         spriteBatch.End()
  90.  
  91.         MyBase.Draw(gameTime)
  92.     End Sub
  93. End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement