Example #1
0
        static void Main(string[] args)
        {
            Oyuncu _oyuncu = new Oyuncu();

            _oyuncu.Ad              = "Eren Subaş";
            _oyuncu.Yas             = 35;
            _oyuncu.YasamDegeri     = 100;
            _oyuncu.OyuncununSilahi = new M51();
            _oyuncu.NisanAl();
            _oyuncu.Yakinlastir();


            _oyuncu.OyuncununSilahi = new Kama();
            _oyuncu.NisanAl();
            _oyuncu.Yakinlastir();


            Console.ReadLine();
        }
Example #2
0
        private void Form1_Load(object sender, EventArgs e)
        {
            Oyuncu p1  = new Oyuncu();
            M51    m51 = new M51();

            p1.Adi   = "Furkan";
            p1.Yas   = "25";
            p1.Silah = m51;
            p1.NisanAl();
            p1.Saldir();
        }