I'm still new to developing games in XNA and using classes with C #, but I want to start a semi-decent game project where I can learn without projects with garbage.
I want to divide my game into classes. For example, the main game class, the player class (I want two players, and they fight each other), the level class (for drawing the world), and maybe later things like the inclusion class and the network class, so I can do everything multi-user.
But I don’t know how best to start using such classes in an XNA game. I am making a class as follows:
namespace MyGame
{
class Player : MyGame
{
}
}
or like this:
namespace MyGame
{
class Player : Microsoft.Xna.Framework.Game
{
}
}
, - Initialize(), Update() Draw(), spriteBatch GraphicsDeviceManager , ... , , , .
. .