protected override void LoadContent()
{
// Create a new SpriteBatch, which can be used to draw textures.
spriteBatch = new SpriteBatch(GraphicsDevice);
Explosion = new AnimatedSprite(
Content.Load<Texture2D>(@"Textures\Explosions"),
0, 0, 64, 64, 16);
Explosion.X = 0;
Explosion.Y = 0;
// TODO: use this.Content to load your game content here
}
此代码出现以下错误:
ContentLoadException was unhandled
Inner exception {"Error loading \"Content\Textures\Explosions.xnb\". File not found.":null}
该文件名为Explosions.png
,位于Textures
文件夹中。
另外,有没有办法确定安装了哪个版本的xna studio?