Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (788)
Games in Android Showcase (234)
games submitted by our members
Games in WIP (863)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Jinput with Xbox Controller (Trigger Question)  (Read 8850 times)
0 Members and 1 Guest are viewing this topic.
Offline Ralph

Innocent Bystander

« Posted 2009-06-06 03:09:43 »

Hey guys,

I've been playing around with Jinput for the past few weeks, and I have run into some trouble regarding the triggers.  (LT and RT).  (They are apparently the z-axis).

What I'm trying to do is get the value from each trigger separately, as they will both control very different things.  What I need is to get how hard each button is being pressed down.

The thing is, it seems as if both buttons act as if they were almost one.  If both buttons aren't being touched, the z-axis is 0.  If both buttons are being held down, the z-axis is also 0.  If one is down and the other isn't, the z-axis is 1 and if the other is down and the other isn't, z-axis is -1.

What I was hoping was that there were a way just to get the -1 -> 0 -> 1 value of each button independently, not as a whole.  Is this possible?

Offline endolf

JGO Coder

Medals: 7
Exp: 15 years

Current project release date: sometime in 3003

« Reply #1 - Posted 2009-06-06 10:58:27 »


This is what the directx driver gives us, so thats all we can do. There is another driver for the Xbox (360) controller that uses xinput, but we don't have a plugin for jinput for that yet, as there is only 1 controller that uses it to expose functionality not available from the directx drivers.


Offline Sardtok

Senior Newbie

« Reply #2 - Posted 2009-07-25 11:57:46 »

You might want to look into XBCD+:

It's a XInput -> DirectX wrapper.
It allows you to set up the mapping whatever way you want (Triggers as separate axes, triggers as buttons, or whatever else you feel like).
Pages: [1]
  ignore  |  Print  

hadezbladez (2209 views)
2018-11-16 13:46:03

hadezbladez (833 views)
2018-11-16 13:41:33

hadezbladez (2165 views)
2018-11-16 13:35:35

hadezbladez (433 views)
2018-11-16 13:32:03

EgonOlsen (3472 views)
2018-06-10 19:43:48

EgonOlsen (3725 views)
2018-06-10 19:43:44

EgonOlsen (2285 views)
2018-06-10 19:43:20

DesertCoockie (3021 views)
2018-05-13 18:23:11

nelsongames (3095 views)
2018-04-24 18:15:36

nelsongames (3911 views)
2018-04-24 18:14:32
Deployment and Packaging
by philfrei
2019-02-17 20:25:53

Deployment and Packaging
by mudlee
2018-08-22 18:09:50

Java Gaming Resources
by gouessej
2018-08-22 08:19:41

Deployment and Packaging
by gouessej
2018-08-22 08:04:08

Deployment and Packaging
by gouessej
2018-08-22 08:03:45

Deployment and Packaging
by philfrei
2018-08-20 02:33:38

Deployment and Packaging
by philfrei
2018-08-20 02:29:55

Deployment and Packaging
by philfrei
2018-08-19 23:56:20 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!