Exemple #1
0
        public GameWindow()
        {
            p1      = new Player(1000, 800, (1000 / 2) - 40, 800, 80, 80, 80);
            rowCars = new Cars[10];
            rowLogs = new Cars[10];

            rowCars[0] = new Cars(1000, 800, 0, 720, 80, 80, 20);
            rowCars[1] = new Cars(1000, 800, -120, 720, 80, 80, 30);
            rowCars[2] = new Cars(1000, 800, -350, 720, 80, 80, 20);

            rowCars[3] = new Cars(1000, 800, 880, 640, 80, 80, 30);
            rowCars[4] = new Cars(1000, 800, 1060, 640, 80, 80, 30);
            rowCars[5] = new Cars(1000, 800, 800, 640, 80, 80, 20);

            rowCars[6] = new Cars(1000, 800, -80, 560, 80, 80, 40);
            rowCars[7] = new Cars(1000, 800, -300, 560, 80, 80, 45);

            rowCars[8] = new Cars(1000, 800, 880, 480, 160, 80, 20);
            rowCars[9] = new Cars(1000, 800, 1000, 480, 160, 80, 25);



            rowLogs[0] = new Cars(1000, 800, 0, 320, 200, 80, 20);
            rowLogs[1] = new Cars(1000, 800, -120, 320, 200, 80, 30);
            rowLogs[2] = new Cars(1000, 800, -350, 320, 200, 80, 20);

            rowLogs[3] = new Cars(1000, 800, 880, 240, 220, 80, 30);
            rowLogs[4] = new Cars(1000, 800, 1060, 240, 220, 80, 30);
            rowLogs[5] = new Cars(1000, 800, 800, 240, 220, 80, 20);

            rowLogs[6] = new Cars(1000, 800, -80, 160, 150, 80, 40);
            rowLogs[7] = new Cars(1000, 800, -300, 160, 150, 80, 45);

            rowLogs[8] = new Cars(1000, 800, 880, 80, 160, 80, 20);
            rowLogs[9] = new Cars(1000, 800, 1000, 80, 160, 80, 25);
            InitializeComponent();
        }
Exemple #2
0
 public void deattach()
 {
     car = null;
 }
Exemple #3
0
 public void attach(Cars c)
 {
     car = c;
 }