/// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { Texture2D tex = Texture2D.FromStream(GraphicsDevice, File.OpenRead(Path)).PreMultiplyAlpha(); Anim = new AnimatableTexture(this, tex); Anim.Initialize(); Arial = this.Content.Load <SpriteFont>("Arial"); }
public void Initialize() { game.RunOneFrame(); tex = new AnimatableTexture(game, Helpers.Load(game, @"Textures\imagem.png")); tex.Initialize(); animator = new Animator(game); animator.AutoRemove = true; animator.Initialize(); }