/* Show map */ public static void ShowMap() { for (int i = 0; i < Harita.getSize(); i++) { for (int j = 0; j < Harita.getSize(); j++) { if (Map.dizi[i, j] == 1) { Console.Write("* "); } else { Console.Write(Map.dizi[i, j] + " "); } } Console.WriteLine(); } }
public static void move(int x, int y) { if (marked) { Harita.mark(Araba.x, Araba.y); } int i_temp = (Araba.x + x) % Harita.getSize(); if (i_temp < 0) { i_temp = Harita.getSize() - 1; } Araba.x = i_temp; i_temp = (Araba.y + y) % Harita.getSize(); if (i_temp < 0) { i_temp = Harita.getSize() - 1; } Araba.y = i_temp; }