public class work:Game
{
public void Shippando()
{
switch (key)
{
case ConsoleKey.W:
if (_variables.ShipY2 > 1)
{
DrawShipR(false);
_variables.ShipY2--;
DrawShipR(true);
}
break;
case ConsoleKey.S:
if (_variables.ShipY2 + GameVariables.SHIP_Height + 1 < Console.WindowHeight - 1)
{
DrawShipR(false);
_variables.ShipY2++;
DrawShipR(true);
}
break;
}
}
}
public class Game
{
work w = new work();
Thread newThread = new Thread(w.Shippando); //
tutaj wyskakuje błąd: A field initializer cannot reference the non-static field, method, or property 'Arkanoid.Game.Game.w'