Ya quedo!
Al que le sirva, le dejo el codigo
Al que le sirva, le dejo el codigo
Código [Seleccionar]
do
{
Console.SetCursorPosition(x, y);
Console.ForegroundColor = ConsoleColor.Red;
Console.WriteLine("@");
keyinfo = Console.ReadKey();
while(keyinfo.Key == ConsoleKey.UpArrow)
{
y = y - 1;
Console.SetCursorPosition(x, y);
Console.ForegroundColor = ConsoleColor.Red;
Console.WriteLine("@");
Console.SetCursorPosition(x, y + 1);
Console.ForegroundColor = ConsoleColor.Black;
Console.WriteLine("@");
break;
}
while (keyinfo.Key == ConsoleKey.DownArrow)
{
y = y + 1;
Console.SetCursorPosition(x, y);
Console.ForegroundColor = ConsoleColor.Red;
Console.WriteLine("@");
Console.SetCursorPosition(x, y - 1);
Console.ForegroundColor = ConsoleColor.Black;
Console.WriteLine("@");
break;
}
while(keyinfo.Key == ConsoleKey.LeftArrow)
{
x = x - 1;
Console.SetCursorPosition(x, y);
Console.ForegroundColor = ConsoleColor.Red;
Console.WriteLine("@");
Console.SetCursorPosition(x+1 , y);
Console.ForegroundColor = ConsoleColor.Black;
Console.WriteLine("@");
break;
}
while (keyinfo.Key == ConsoleKey.RightArrow)
{
x = x + 1;
Console.SetCursorPosition(x, y);
Console.ForegroundColor = ConsoleColor.Red;
Console.WriteLine("@");
Console.SetCursorPosition(x-1,y);
Console.ForegroundColor = ConsoleColor.Black;
Console.WriteLine("@");
break;
}
}
while (keyinfo.Key != ConsoleKey.Enter);