public GameStateManager(GraphicsDeviceManager man,ContentManager cman,MineWorldClient gam) { Audiomanager = new AudioManager(); Config = new ConfigFile("data/settings.ini"); _inputhelper = new InputHelper(); Game = gam; Conmanager = cman; Graphics = man; Device = Graphics.GraphicsDevice; SpriteBatch = new SpriteBatch(Device); _screens = new BaseState[] { new TitleState(this, GameState.TitleState), new MainMenuState(this, GameState.MainMenuState), new LoadingState(this, GameState.LoadingState), new MainGameState(this, GameState.MainGameState), new SettingsState(this, GameState.SettingsState), _serverbrowsingstate = new ServerBrowsingState(this, GameState.ServerBrowsingState), _errorstate = new ErrorState(this, GameState.ErrorState) }; //curScreen = titlestate; Pbag = new PropertyBag(gam,this); //Set initial state in the manager itself SwitchState(GameState.TitleState); }
public ClientListener(NetClient netc, PropertyBag pb) { _client = netc; _pbag = pb; }
public ClientSender(NetClient netc, PropertyBag pb) { _client = netc; _pbag = pb; }
public Debug(PropertyBag gameIn) { _game = gameIn; }
//Constructor public Player(PropertyBag gameIn) { Cam = new Camera(gameIn, new Vector3(0, 64, 0), new Vector3(0, 0, 0)); _game = gameIn; }
/// <summary> /// Creates a 3D camera object /// </summary> /// <param name="game">Game reference</param> /// <param name="pos">Camera position</param> /// <param name="ang">Camera angle</param> public Camera(PropertyBag game, Vector3 pos, Vector3 ang) { _pos = pos; _ang = ang; SetPerspective(MathHelper.ToRadians(90),game.GameManager.Device.Viewport.AspectRatio, 0.01f, 100000.0f); }