You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
714 B
29 lines
714 B
using CoreLibrary;
|
|
using CoreLibrary.Events;
|
|
using CoreLibrary.Regles;
|
|
|
|
namespace MauiSpark.Pages;
|
|
|
|
public partial class Mode : ContentPage
|
|
{
|
|
public Mode()
|
|
{
|
|
NavigationPage.SetHasBackButton(this, false);
|
|
NavigationPage.SetHasNavigationBar(this, false);
|
|
|
|
InitializeComponent();
|
|
}
|
|
|
|
private void QuandReglesClassiques(Object? sender, EventArgs e)
|
|
{
|
|
Partie partie = new Partie(new ReglesClassiques());
|
|
partie.DemanderNom += QuandDemanderNom;
|
|
partie.Jouer();
|
|
}
|
|
|
|
private void QuandDemanderNom(Object? sender, DemanderNomEventArgs e)
|
|
{
|
|
if(sender != null && sender is Partie)
|
|
Navigation.PushAsync(new ConnexionPage(sender as Partie, e));
|
|
}
|
|
} |