示例#1
0
        static void Main(string[] args)
        {
            GamerManager gamerManager = new GamerManager(new UserValidationManager());
            Gamer        gamer        = new Gamer {
                Id = 8, BirthYear = 1999, FirstName = "Güzin", LastName = "Kanburoglu", IdentityNumber = 123456
            };

            gamerManager.Add(gamer);

            Campaigns campaign1 = new Campaigns {
                Id = 1, Name = "Christmas Sale", Sale = 0.50
            };
            Campaigns campaign2 = new Campaigns {
                Id = 2, Name = "The Game Awards Sale", Sale = 0.30
            };

            CampaignManager campaignManager = new CampaignManager();

            campaignManager.Add(campaign1);
            campaignManager.Add(campaign2);

            Games game = new Games {
                Name = "GTA", Price = 100
            };

            Console.WriteLine("Price is: " + campaignManager.Sale(game, campaign1));
        }
示例#2
0
        static void Main(string[] args)
        {
            Console.WriteLine("Hello World!");

            Gamer gamer1 = new Gamer();

            gamer1.TC          = 12345;
            gamer1.Name        = "Game";
            gamer1.Surname     = "Boi";
            gamer1.ID          = 1;
            gamer1.DateOfBirth = 1987;

            Gamer gamer2 = new Gamer();

            gamer2.TC          = 56789;
            gamer2.Name        = "Tech";
            gamer2.Surname     = "Girl";
            gamer2.DateOfBirth = 1996;


            AccountManager accountManager = new AccountManager(new UserValidationManager());

            accountManager.Add(gamer1);

            Campaigns campaign1 = new Campaigns();

            campaign1.CampaignName = "10% İndirim";
            campaign1.CampaignId   = 1;
            campaign1.Description  = "Her oyunda 10% indirim";
            CampaignManager campaignManager = new CampaignManager();

            campaignManager.Add(campaign1);

            Games game1 = new Games();

            game1.GameId      = 5;
            game1.GameName    = "Cyberpunk 2077";
            game1.Description = "Cyberpunk";
            Orders order1 = new Orders();

            order1.OrderId = 2;

            OrderManager orderManager = new OrderManager(new UserValidationManager());

            orderManager.AddOrder(gamer1, game1);

            orderManager.AddOrder(gamer2, game1, campaign1);
        }
示例#3
0
 public void Campaignz(Player player, Campaigns campaigns)
 {
     campaigns.Campaignsx(player);
 }
 public void Add(Campaigns campaign)
 {
     Console.WriteLine("Kampanya sisteme eklendi");
 }
 public void Delete(Campaigns campaign)
 {
     Console.WriteLine("Kampanya silindi");
 }
 public void Update(Campaigns campaign)
 {
     Console.WriteLine("Kampanya güncellendi");
 }
示例#7
0
 public void Add(Campaigns campaign)
 {
     Console.WriteLine("Campaign is added: " + campaign.Name);
 }
示例#8
0
 public void Update(Campaigns campaign)
 {
     Console.WriteLine("Campaign is updated: " + campaign.Name);
 }
示例#9
0
 public double Sale(Games game, Campaigns campaign)
 {
     return(game.Price * campaign.Sale);
 }
示例#10
0
 public void Delete(Campaigns campaign)
 {
     Console.WriteLine("Campaign is deleted: " + campaign.Name);
 }
示例#11
0
 public void AddOrder(Gamer gamer, Games game, Campaigns campaign)
 {
     Console.WriteLine(gamer.Name + " kullanıcısı " + game.GameName + " oyununu aldı\nKampanyanız: " + campaign.CampaignName);
 }