Using KeyPressEventArgs
I want to be able to detect multiple keypresses. I have tried it like this without luck.
[GLib.ConnectBefore]
public override void OnKeyPress (object o, global::Gtk.KeyPressEventArgs args)
{
if ((args.Event.Key == Gdk.Key.Up) && (args.Event.Key == Gdk.Key.Right))
{
playerPhysics.AddVector (_taxiGoUp);
Player._state = Taxi.State.MoveUp;
playerPhysics.AddVector (_taxiGoRight);
Player._state = Taxi.State.MoveRight;
}
}
Can anyone help figuring this out?