示例#1
0
        public void updateLayer(Microsoft.Xna.Framework.GameTime gameTime)
        {
            //components
            _components.Update(gameTime);
            //update tiles
            for (int i = 0; i < _tiles.Count; i++)
            {
                CTile   tile       = _tiles[i];
                Vector2 dimensions = Vector2.Zero;

                //get tileset info
                if (string.IsNullOrEmpty(tile.tileSet))
                {
                    dimensions = _imageVector;
                }
                else
                {
                    dimensions = tile.dimensions;
                }

                tile.shouldDraw = CMasterControl.buttonController.checkCullBoundary(tile.tileCoords, dimensions);

                if (tile.shouldDraw)
                {
                    tile.update();
                }
            }
        }
示例#2
0
 public void updateLayer(Microsoft.Xna.Framework.GameTime gameTime)
 {
     //components
     _components.Update(gameTime);
 }