Questions tagged [gamecontroller]

74 questions
0
votes
0 answers

Use Windows.Gaming.Input (GameInput) in Windows Form C#

I want to Use Windows.Gaming.Input (GameInput) in Windows Form project. I found this link, But I could not add Windows.Gaming. I have created a project in Microsoft Visual Studio 2022 (.Net 5.0), Then i after created and changed it to .Net Framework…
Saeed
  • 1
  • 1
  • 1
0
votes
1 answer

Simulate keyboard key press in Python to play games on Linux?

I'd like to simulate keyboard events, mainly WASD from Python to control games on Linux. So far, I've tried PyKey and Keyboard module but unfortunately, they are unable to simulate the keypress in a way that games detect it as continuous movement…
Wor Chan
  • 139
  • 1
  • 11
0
votes
0 answers

Using Joystick without pygame in an Qt application

Is there any way to embed a joystick or a game controller with an eventlistener in python program pygame? Gladly also directly with PyQt. There is a nice widget in Qt for the keyboard. Is there something similar for the gamecontoller? Many thanks…
0
votes
1 answer

Trying to make my first game with pygame and after making the title screen, I've been unable to change my players image

I've been making a game where a car drives around an open road eating other cars. Pressing spacebar allows the player car to transform and cannibalize other cars until any key event is finished. I had to turn my main game loop into a function to get…
0
votes
1 answer

Detect/override controller "Home" button press android

I have an android application that is meant to be used with a game controller connected to the android device. Most game controllers have a center 'home' button that I would like to use to pause the game (for example, an Xbox controller center nexus…
alexward1230
  • 579
  • 3
  • 8
  • 25
0
votes
1 answer

Swift Macos GameController not showing. Controller.count return zero

I'm developing an app which includes Gamecontroller. I'm trying to show the connected controller count, but it´s not working. Here is my simple code: import Cocoa import GameController @NSApplicationMain class AppDelegate: NSObject,…
0
votes
1 answer

My characters Sensitive. Y Axis is working but not my X Axis

enter image description here I've been following this YouTube video tutorial https://youtu.be/PmIPqGqp8UY and everything was going well my X Axis was working well than I tried working on the Y Axis but for some reason the Y Axis works and now the X…
0
votes
1 answer

How not to let Home button quit your tvOS app in SwiftUI

In UIKit we can use GCEventViewController to intercept the game controllers from propagating Home button presses to the responders (and have them quit our app) by setting controllerUserInteractionEnabled = false SwiftUI Apps do not use…
TarqTeles
  • 41
  • 7
0
votes
1 answer

How to select and click on child views of Android ViewPager2 with Dpad/Game Controller

I am investigating Bluetooth Dpad and game controllers in my current Android Project. I can successfully select and click on all my UI widets within my App. However I have a ViewPager2 that holds multiple fragments and I am unable to select or click…
Hector
  • 4,016
  • 21
  • 112
  • 211
0
votes
0 answers

How do you parse information from a Human Interface Device / HID?

I may not even know enough about interacting with HIDs to ask a good question, but here's my best shot so far. I am using C# and am on Windows currently. I have been researching how to interact with a game controller like a PlayStation 4 or…
Brett Lesnau
  • 208
  • 3
  • 8
0
votes
1 answer

Problem in character control "Character can't jump"

I am practicing with creating a 2D-Game and I write the C#-script code but my character can't jump. I try to replace "Space" with "UpArrow" that also didn't work. if (Input.GetKey(KeyCode.UpArrow) && onGround) { rb.velocity = new…
Sagar Yadav
  • 109
  • 2
  • 10
0
votes
0 answers

Android: reading gamepad (gamecontroller) events from an application not in view

Reading USB gamepad events (button press etc.) from an application in view (focus) might not be an issue on Android. The problem is that I need these events from a persistent application/service/etc. which is not necessary in view (e.g. a foreground…
Zoltán Bíró
  • 346
  • 1
  • 12
0
votes
2 answers

BLE and Bluetooth gamepad options for Oculus

I'm planning to build a mobile app that sends over BLE a joystick commands with HID over GATT. Does Oculus external gamepad option will be able to connect to it? or it works only with Bluetooth?? therefore BLE won't work? I would appreciate if you…
0
votes
1 answer

SDL2_pollevent() Controller dpad continuous hold?

I'm trying to register controller button/dpad presses and continuous hold of said buttons that way it spits the output out continuously instead of one press at a time and then exiting the poll event loop. Right now I have a small piece of dummy …
alm2022
  • 87
  • 1
  • 6
0
votes
0 answers

Right/Left Trigger Values in Pygame

I'm using pygame to map values from my Logitech Cordless Rumblepad 2 and when i try to pull values from the right/left trigger buttons I can only retrieve binary values of 1-0 for button state down and up. Am I mistaken in thinking that the trigger…