public void LoadPiles(GalaxyCardGameMainGameClass mainGame, GalaxyCardGameVMData model, CommandContainer command)
        {
            _mainGame  = mainGame;
            _model     = model;
            PlanetHand = new HandObservable <GalaxyCardGameCardInformation>(command);
            PlanetHand.BoardClickedAsync += PlanetHand_BoardClickedAsync;
            PlanetHand.Maximum            = 2;
            PlanetHand.Visible            = true;
            PlanetHand.Text = $"{NickName} Planet";
            //PlanetHand.SendEnableProcesses(mainGame.ThisMod!, () =>
            //{
            //    if (PlayerCategory != EnumPlayerCategory.Self)
            //        return false;
            //    if (mainGame.SaveRoot!.GameStatus != EnumGameStatus.PlaceSets)
            //        return false;
            //    return mainGame.HasAutomaticPlanet() || PlanetHand.HandList.Count == 0;

            //});
            Moons = new MainSetsObservable <EnumSuitList, EnumColorList, GalaxyCardGameCardInformation, MoonClass, SavedSet>(command);
            Moons.SetClickedAsync += Moons_SetClickedAsync;
            Moons.HasFrame         = true;
            Moons.Text             = $"{NickName} Moons";
            //Moons.Visible = true;
            //Moons.SendEnableProcesses(mainGame.ThisMod!, () =>
            //{
            //    if (PlayerCategory != EnumPlayerCategory.Self)
            //        return false;
            //    return CanEnableMoon();
            //});
        }
Example #2
0
 public MonopolyCardGameVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1           = new DeckObservablePile <MonopolyCardGameCardInformation>(aggregator, command);
     Pile1           = new PileObservable <MonopolyCardGameCardInformation>(aggregator, command);
     PlayerHand1     = new HandObservable <MonopolyCardGameCardInformation>(command);
     AdditionalInfo1 = new DetailCardViewModel();
 }
        public XactikaVMData(IEventAggregator aggregator,
                             CommandContainer command,
                             BasicTrickAreaObservable <EnumShapes, XactikaCardInformation> trickArea1,
                             XactikaGameContainer gameContainer
                             )
        {
            Deck1          = new DeckObservablePile <XactikaCardInformation>(aggregator, command);
            Pile1          = new PileObservable <XactikaCardInformation>(aggregator, command);
            PlayerHand1    = new HandObservable <XactikaCardInformation>(command);
            TrickArea1     = trickArea1;
            _gameContainer = gameContainer;
            ModeChoose1    = new ListViewPicker(command, gameContainer.Resolver);
            ShapeChoose1   = new ChooseShapeObservable(_gameContainer);
            Bid1           = new NumberPicker(command, gameContainer.Resolver);
            ModeChoose1.ItemSelectedAsync += ModeChooser1_ItemSelectedAsync;
            Bid1.ChangedNumberValueAsync  += Bid1_ChangedNumberValueAsync;
            PlayerHand1 !.Maximum          = 8;
            ModeChoose1.IndexMethod        = EnumIndexMethod.OneBased;
            CustomBasicList <string> tempList = new CustomBasicList <string> {
                "To Win", "To Lose", "Bid"
            };

            ModeChoose1.LoadTextList(tempList);
            ShapeChoose1.SendEnableProcesses(this, (() => _gameContainer.SaveRoot.GameStatus == EnumStatusList.CallShape));
        }
Example #4
0
 public ConcentrationVMData(IEventAggregator aggregator, CommandContainer command, ConcentrationGameContainer gameContainer)
 {
     Deck1       = new DeckObservablePile <RegularSimpleCard>(aggregator, command);
     Pile1       = new PileObservable <RegularSimpleCard>(aggregator, command);
     PlayerHand1 = new HandObservable <RegularSimpleCard>(command);
     GameBoard1  = new GameBoardClass(gameContainer);
 }
Example #5
0
 public CrazyEightsVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1       = new DeckObservablePile <RegularSimpleCard>(aggregator, command);
     Pile1       = new PileObservable <RegularSimpleCard>(aggregator, command);
     PlayerHand1 = new HandObservable <RegularSimpleCard>(command);
     SuitChooser = new SimpleEnumPickerVM <EnumSuitList, DeckPieceCP>(command, new SuitListChooser());
     SuitChooser.AutoSelectCategory = EnumAutoSelectCategory.AutoEvent;
 }
Example #6
0
 public FourSuitRummyVMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver)
 {
     Deck1                = new DeckObservablePile <RegularRummyCard>(aggregator, command);
     Pile1                = new PileObservable <RegularRummyCard>(aggregator, command);
     PlayerHand1          = new HandObservable <RegularRummyCard>(command);
     TempSets             = new TempSetsObservable <EnumSuitList, EnumColorList, RegularRummyCard>(command, resolver);
     TempSets.HowManySets = 5;
 }
 public GoFishVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1       = new DeckObservablePile <RegularSimpleCard>(aggregator, command);
     Pile1       = new PileObservable <RegularSimpleCard>(aggregator, command);
     PlayerHand1 = new HandObservable <RegularSimpleCard>(command);
     AskList     = new GoFishChooserCP(command);
     AskList.AutoSelectCategory = EnumAutoSelectCategory.AutoEvent;             //i think.
 }
Example #8
0
 public FillOrBustVMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver)
 {
     Deck1       = new DeckObservablePile <FillOrBustCardInformation>(aggregator, command);
     Pile1       = new PileObservable <FillOrBustCardInformation>(aggregator, command);
     PlayerHand1 = new HandObservable <FillOrBustCardInformation>(command);
     _command    = command;
     _resolver   = resolver;
 }
 public FlinchVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1       = new DeckObservablePile <FlinchCardInformation>(aggregator, command);
     Pile1       = new PileObservable <FlinchCardInformation>(aggregator, command);
     PlayerHand1 = new HandObservable <FlinchCardInformation>(command);
     StockPile   = new StockViewModel(command, aggregator);
     PublicPiles = new PublicPilesViewModel(command);
 }
 public SorryCardGameVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1          = new DeckObservablePile <SorryCardGameCardInformation>(aggregator, command);
     Pile1          = new PileObservable <SorryCardGameCardInformation>(aggregator, command);
     PlayerHand1    = new HandObservable <SorryCardGameCardInformation>(command);
     OtherPile      = new PileObservable <SorryCardGameCardInformation>(aggregator, command);
     OtherPile.Text = "Play Pile";
     OtherPile.FirstLoad(new SorryCardGameCardInformation());
 }
 public FiveCrownsVMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver)
 {
     Deck1                = new DeckObservablePile <FiveCrownsCardInformation>(aggregator, command);
     Pile1                = new PileObservable <FiveCrownsCardInformation>(aggregator, command);
     PlayerHand1          = new HandObservable <FiveCrownsCardInformation>(command);
     TempSets             = new TempSetsObservable <EnumSuitList, EnumColorList, FiveCrownsCardInformation>(command, resolver);
     MainSets             = new MainSetsObservable <EnumSuitList, EnumColorList, FiveCrownsCardInformation, PhaseSet, SavedSet>(command);
     TempSets.HowManySets = 6;
 }
 public Phase10VMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver)
 {
     Deck1                = new DeckObservablePile <Phase10CardInformation>(aggregator, command);
     Pile1                = new PileObservable <Phase10CardInformation>(aggregator, command);
     PlayerHand1          = new HandObservable <Phase10CardInformation>(command);
     TempSets             = new TempSetsObservable <EnumColorTypes, EnumColorTypes, Phase10CardInformation>(command, resolver);
     MainSets             = new MainSetsObservable <EnumColorTypes, EnumColorTypes, Phase10CardInformation, PhaseSet, SavedSet>(command);
     TempSets.HowManySets = 5;
 }
 public OldMaidVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1                     = new DeckObservablePile <RegularSimpleCard>(aggregator, command);
     Pile1                     = new PileObservable <RegularSimpleCard>(aggregator, command);
     PlayerHand1               = new HandObservable <RegularSimpleCard>(command);
     OpponentCards1            = new HandObservable <RegularSimpleCard>(command);
     OpponentCards1.Text       = "Opponent Cards";
     OpponentCards1.AutoSelect = HandObservable <RegularSimpleCard> .EnumAutoType.None;
 }
 public Rummy500VMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1         = new DeckObservablePile <RegularRummyCard>(aggregator, command);
     Pile1         = new PileObservable <RegularRummyCard>(aggregator, command);
     PlayerHand1   = new HandObservable <RegularRummyCard>(command);
     MainSets1     = new MainSetsObservable <EnumSuitList, EnumColorList, RegularRummyCard, RummySet, SavedSet>(command);
     DiscardList1  = new DiscardListCP(command);
     Pile1.Visible = false;
 }
Example #15
0
 public MonasteryCardGameVMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver)
 {
     Deck1                = new DeckObservablePile <MonasteryCardInfo>(aggregator, command);
     Pile1                = new PileObservable <MonasteryCardInfo>(aggregator, command);
     PlayerHand1          = new HandObservable <MonasteryCardInfo>(command);
     TempSets             = new TempSetsObservable <EnumSuitList, EnumColorList, MonasteryCardInfo>(command, resolver);
     MainSets             = new MainSetsObservable <EnumSuitList, EnumColorList, MonasteryCardInfo, RummySet, SavedSet>(command);
     TempSets.HowManySets = 4;
 }
 public ChinazoVMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver)
 {
     Deck1                = new DeckObservablePile <ChinazoCard>(aggregator, command);
     Pile1                = new PileObservable <ChinazoCard>(aggregator, command);
     PlayerHand1          = new HandObservable <ChinazoCard>(command);
     TempSets             = new TempSetsObservable <EnumSuitList, EnumColorList, ChinazoCard>(command, resolver);
     MainSets             = new MainSetsObservable <EnumSuitList, EnumColorList, ChinazoCard, PhaseSet, SavedSet>(command);
     TempSets.HowManySets = 5;
 }
 public CousinRummyVMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver)
 {
     Deck1                = new DeckObservablePile <RegularRummyCard>(aggregator, command);
     Pile1                = new PileObservable <RegularRummyCard>(aggregator, command);
     PlayerHand1          = new HandObservable <RegularRummyCard>(command);
     TempSets             = new TempSetsObservable <EnumSuitList, EnumColorList, RegularRummyCard>(command, resolver);
     MainSets             = new MainSetsObservable <EnumSuitList, EnumColorList, RegularRummyCard, PhaseSet, SavedSet>(command);
     TempSets.HowManySets = 8;
     MainSets.Text        = "Main Sets";
 }
        //for mexican train dominos, will go ahead and change the type of dominos used.

        public ItalianDominosVMData(CommandContainer command,
                                    IGamePackageResolver resolver,
                                    DominosBasicShuffler <SimpleDominoInfo> shuffle
                                    )
        {
            PlayerHand1 = new HandObservable <SimpleDominoInfo>(command);
            BoneYard    = new DominosBoneYardClass <SimpleDominoInfo>(this, command, resolver, shuffle);
            PlayerHand1.ObjectClickedAsync += PlayerHand1_ObjectClickedAsync;
            PlayerHand1.BoardClickedAsync  += PlayerHand1_BoardClickedAsync;
        }
 public SkipboVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1       = new DeckObservablePile <SkipboCardInformation>(aggregator, command);
     Pile1       = new PileObservable <SkipboCardInformation>(aggregator, command);
     PlayerHand1 = new HandObservable <SkipboCardInformation>(command);
     StockPile   = new StockViewModel(command, aggregator);
     //DiscardPiles = new DiscardPilesVM<SkipboCardInformation>(command, aggregator);
     //DiscardPiles.Init(HowManyDiscards); //hopefully this simple (?)
     PublicPiles = new PublicPilesViewModel(command, aggregator);
 }
 public RackoVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1                 = new DeckObservablePile <RackoCardInformation>(aggregator, command);
     Pile1                 = new PileObservable <RackoCardInformation>(aggregator, command);
     PlayerHand1           = new HandObservable <RackoCardInformation>(command);
     OtherPile             = new PileObservable <RackoCardInformation>(aggregator, command);
     OtherPile.Text        = "Current Card";
     OtherPile.CurrentOnly = true;
     OtherPile.FirstLoad(new RackoCardInformation());
 }
 public CaliforniaJackVMData(IEventAggregator aggregator,
                             CommandContainer command,
                             BasicTrickAreaObservable <EnumSuitList, CaliforniaJackCardInformation> trickArea1
                             )
 {
     Deck1       = new DeckObservablePile <CaliforniaJackCardInformation>(aggregator, command);
     Pile1       = new PileObservable <CaliforniaJackCardInformation>(aggregator, command);
     PlayerHand1 = new HandObservable <CaliforniaJackCardInformation>(command);
     TrickArea1  = trickArea1;
 }
Example #22
0
 public RoundsCardGameVMData(IEventAggregator aggregator,
                             CommandContainer command,
                             BasicTrickAreaObservable <EnumSuitList, RoundsCardGameCardInformation> trickArea1
                             )
 {
     Deck1       = new DeckObservablePile <RoundsCardGameCardInformation>(aggregator, command);
     Pile1       = new PileObservable <RoundsCardGameCardInformation>(aggregator, command);
     PlayerHand1 = new HandObservable <RoundsCardGameCardInformation>(command);
     TrickArea1  = trickArea1;
 }
 public OpetongVMData(IEventAggregator aggregator, CommandContainer command, IGamePackageResolver resolver, OpetongGameContainer gameContainer)
 {
     Deck1                = new DeckObservablePile <RegularRummyCard>(aggregator, command);
     Pile1                = new PileObservable <RegularRummyCard>(aggregator, command);
     PlayerHand1          = new HandObservable <RegularRummyCard>(command);
     TempSets             = new TempSetsObservable <EnumSuitList, EnumColorList, RegularRummyCard>(command, resolver);
     TempSets.HowManySets = 3;
     //hopefully no problem with init each time.
     MainSets = new MainSetsObservable <EnumSuitList, EnumColorList, RegularRummyCard, RummySet, SavedSet>(command);
     Pool1    = new CardPool(gameContainer);
 }
 public UnoVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1            = new DeckObservablePile <UnoCardInformation>(aggregator, command);
     Pile1            = new PileObservable <UnoCardInformation>(aggregator, command);
     PlayerHand1      = new HandObservable <UnoCardInformation>(command);
     PlayerHand1.Text = "Your Cards";
     ColorPicker      = new SimpleEnumPickerVM <EnumColorTypes, CheckerChoiceCP <EnumColorTypes> >(command, new ColorListChooser <EnumColorTypes>());
     Stops            = new CustomStopWatchCP();
     Stops.MaxTime    = 3000;
     ColorPicker.AutoSelectCategory = EnumAutoSelectCategory.AutoEvent;
 }
 public TeeItUpVMData(IEventAggregator aggregator, CommandContainer command)
 {
     Deck1                 = new DeckObservablePile <TeeItUpCardInformation>(aggregator, command);
     Pile1                 = new PileObservable <TeeItUpCardInformation>(aggregator, command);
     PlayerHand1           = new HandObservable <TeeItUpCardInformation>(command);
     OtherPile             = new PileObservable <TeeItUpCardInformation>(aggregator, command);
     OtherPile.CurrentOnly = true;
     OtherPile.Text        = "Current Card";
     OtherPile.FirstLoad(new TeeItUpCardInformation());
     PlayerHand1.Visible = false;             //try this too.
 }
        public LifeCardGameVMData(IEventAggregator aggregator, CommandContainer command)
        {
            Deck1       = new DeckObservablePile <LifeCardGameCardInformation>(aggregator, command);
            Pile1       = new PileObservable <LifeCardGameCardInformation>(aggregator, command);
            PlayerHand1 = new HandObservable <LifeCardGameCardInformation>(command);
            CurrentPile = new PileObservable <LifeCardGameCardInformation>(aggregator, command);

            CurrentPile.Text = "Current Card";

            OtherPile = CurrentPile;
        }
 public RaglanSolitaireMainViewModel(IEventAggregator aggregator,
     CommandContainer command, 
     IGamePackageResolver resolver
     )
     : base(aggregator, command, resolver)
 {
     Stock1 = new HandObservable<SolitaireCard>(command);
     Stock1.Maximum = 6;
     Stock1.Text = "Stock";
     GlobalClass.Stock = Stock1;
 }
 public GolfCardGameVMData(IEventAggregator aggregator, CommandContainer command, GolfCardGameGameContainer gameContainer)
 {
     Deck1                 = new DeckObservablePile <RegularSimpleCard>(aggregator, command);
     Pile1                 = new PileObservable <RegularSimpleCard>(aggregator, command);
     PlayerHand1           = new HandObservable <RegularSimpleCard>(command);
     OtherPile             = new PileObservable <RegularSimpleCard>(aggregator, command);
     OtherPile.CurrentOnly = true;
     OtherPile.Text        = "Current";
     HiddenCards1          = new HiddenCards(gameContainer);
     Beginnings1           = new Beginnings(command);
     GolfHand1             = new GolfHand(gameContainer);
 }
Example #29
0
        public MillebournesVMData(IEventAggregator aggregator, CommandContainer command)
        {
            Deck1       = new DeckObservablePile <MillebournesCardInformation>(aggregator, command);
            Pile1       = new PileObservable <MillebournesCardInformation>(aggregator, command);
            PlayerHand1 = new HandObservable <MillebournesCardInformation>(command);
            OtherPile   = Pile1;

            Pile2 = new PileObservable <MillebournesCardInformation>(aggregator, command);

            Stops         = new CustomStopWatchCP();
            Stops.MaxTime = 3000;
        }
 public ClueBoardGameVMData(CommandContainer command, IGamePackageResolver resolver, IEventAggregator aggregator)
 {
     _command            = command;
     _resolver           = resolver;
     HandList            = new HandObservable <CardInfo>(command);
     HandList.AutoSelect = HandObservable <CardInfo> .EnumAutoType.None;
     HandList.Maximum    = 3;
     HandList.Text       = "Your Cards";
     Pile             = new PileObservable <CardInfo>(aggregator, command);
     Pile.CurrentOnly = true;
     Pile.Text        = "Clue";
 }