private async void T_Tick(object sender, EventArgs e)
{
if (Gamepad.Gamepads.Count > 0)
{
Controller = Gamepad.Gamepads.First();
var Reading = Controller.GetCurrentReading();
switch (Reading.Buttons) {
case GamepadButtons.DPadUp:
Process[] process = Process.GetProcessesByName("RobloxPlayerBeta");
Process robloxProcess = process.FirstOrDefault();
if (robloxProcess != null)
{
IntPtr h = robloxProcess.MainWindowHandle;
SetForegroundWindow(h);
await Log("We're tabbed in");
InputSimulator inputSim = new InputSimulator();
inputSim.Mouse.VerticalScroll(3);
}
break;
// add other buttons here
}
return;
}
}
private async void T_Tick(object sender, EventArgs e)
{
if (Gamepad.Gamepads.Count > 0)
{
Controller = Gamepad.Gamepads.First();
var Reading = Controller.GetCurrentReading();
switch (Reading.Buttons) {
case GamepadButtons.DPadUp:
Process[] process = Process.GetProcessesByName("RobloxPlayerBeta");
Process robloxProcess = process.FirstOrDefault();
if (robloxProcess != null)
{
IntPtr h = robloxProcess.MainWindowHandle;
SetForegroundWindow(h);
await Log("We're tabbed in");
InputSimulator inputSim = new InputSimulator();
inputSim.Mouse.VerticalScroll(3);
}
break;
// add other buttons here
}
return;
}
}