public virtual void Update(GameTime gameTime)
{
étatTactile = TouchPanel.GetState();
if (étatTactile.Count > 0)
{
foreach (TouchLocation location in étatTactile)
{
Point touchLocation = new Point((int)location.Position.X, (int)location.Position.Y);
foreach (Bouton bouton in Boutons)
{
if (bouton.emplacementBouton.Contains(touchLocation))
{
bouton.Agir();
}
}
}
}
if (background1.rectangle.Y > fenêtre.Height)
{
background1.rectangle.Y = background2.rectangle.Y - background1.texture.Height;
}
if (background2.rectangle.Y > fenêtre.Height)
{
background2.rectangle.Y = background1.rectangle.Y - background2.texture.Height;
}
background1.Update();
background2.Update();
}