public Player(Game1 game) : base(game) { _game = game; _yaw = _pitch = 0; _position = Vector3.Zero; _jumping = false; _currentGravity = Map.AIR_GRAVITY; _blockAccessor = new BlockAccessor(_game.Map); }
public Chunk(Game1 game, Vector3 offset, Block[] blocks) { _game = game; _offset = offset; _boundingBox = new BoundingBox( new Vector3(_offset.X * WIDTH, _offset.Y * HEIGHT, _offset.Z * DEPTH), new Vector3((_offset.X + 1) * WIDTH, (_offset.Y + 1) * HEIGHT, (_offset.Z + 1) * DEPTH)); _solidVertexList = new List<VertexPositionNormalTexture>(); _solidIndexList = new List<int>(); _solidIndicesDict = new Dictionary<int,List<int>>(); _solidBlocksOffsetsList = new List<int>(); _liquidVertexList = new List<VertexPositionNormalTexture>(); _liquidIndexList = new List<int>(); _liquidIndicesDict = new Dictionary<int, List<int>>(); _liquidBlocksOffsetsList = new List<int>(); _blocks = blocks; _blockAccessor = new BlockAccessor(_game.Map); _effect = new BasicEffect(_game.GraphicsDevice); }