GameControlManager

Has anyone got a 'complete' example of GameControlManager in use. Ive read a lot of semi complete samples and taken a look at the Test class using it, but its not very clear how to use the control manager as intended.

TestGameSettingsManager (or something like that) is an operational example of usage.



I use it extensively in Galaxies Beyond and it's working very well.

Yes I saw a snippet of your thruster,pitch/yaw/roll code. I'll give this test class a shot.

Nope cant find it anywhere.



I've seen this one:

https://jme.dev.java.net/source/browse/jme/src/jmetest/input/controls/TestSwingControlEditor.java?view=markup

…yeah, that's it. :wink:

I'd have to say, after using GameControls I can see how much more powerful and flexible they are over the InputHandler approach.  It took a while to understand the concept and all the permutations of usage available primarily through experimentations.  It would be nice to see a bit more documentation from the frog

well, actually neither of them (InputHandler nor GameControlManager) is more powerful or flexible. InputHandler is event-based and GameControlManager is polling states.

Ok well, it "appears" more powerful (to me) - I can already see how im going to implement a complex control system (hundreds of controls) in to my game states with ease, and whilst avoiding conflicting actions and the laborious activation and deactivation of input events that I would have had to undertake previously.



I guess each methodology may be more appropriate according to ones particular needs.

irrisor said:

well, actually neither of them (InputHandler nor GameControlManager) is more powerful or flexible. InputHandler is event-based and GameControlManager is polling states.


I'm expecting you'll agree with this clarification, but I would say rather each of them is more powerful and flexible in its own way.  Feature-wise GameControls are very specifically engineered for game development whereas InputHandler is a more generic approach of event handling.  I am by no means that InputHandler should never be used again, but rather trying to get people to do a side-by-side comparison.  I think in the majority of cases games developed around here could benefit from the features of GameControls rather than trying to make InputHandler fit their needs.
irrisor said:

well, actually neither of them (InputHandler nor GameControlManager) is more powerful or flexible. InputHandler is event-based and GameControlManager is polling states.


then what is?