From ab1cbf70686f05d722532254e838cfaed97f5023 Mon Sep 17 00:00:00 2001 From: Tharushi Date: Fri, 31 May 2019 16:03:05 +1000 Subject: [PATCH 1/2] changes the snap file added a cunstructor --- src/GameLogic/Snap.cs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/GameLogic/Snap.cs b/src/GameLogic/Snap.cs index 42894a1a..19d7e7f8 100644 --- a/src/GameLogic/Snap.cs +++ b/src/GameLogic/Snap.cs @@ -14,8 +14,15 @@ namespace CardGames.GameLogic /// public class Snap { - // Keep only the last two cards... - private readonly Card[] _topCards = new Card[2]; + public Snap() + { + _deck = new Deck(); + _gameTimer = SwinGame.CreateTimer + (); + } + + // Keep only the last two cards... + private readonly Card[] _topCards = new Card[2]; // Have a Deck of cards to play with. private readonly Deck _deck; From d42bfd8bec85c93aef156c3f1be783a13972e206 Mon Sep 17 00:00:00 2001 From: Tharushi Date: Fri, 31 May 2019 16:06:53 +1000 Subject: [PATCH 2/2] change is done to the snap file --- src/GameLogic/Snap.cs | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/GameLogic/Snap.cs b/src/GameLogic/Snap.cs index 19d7e7f8..d39d9029 100644 --- a/src/GameLogic/Snap.cs +++ b/src/GameLogic/Snap.cs @@ -14,12 +14,7 @@ namespace CardGames.GameLogic /// public class Snap { - public Snap() - { - _deck = new Deck(); - _gameTimer = SwinGame.CreateTimer - (); - } + // Keep only the last two cards... private readonly Card[] _topCards = new Card[2];