How do I completely disable input?

I’m reading a book on JME3, and I think it’s a little bit outdated. It’s telling me to use a userInput(false) method of the AppSettings class, but it doesn’t even have any parameters :confused: So could someone help me?

1 Like

https://wiki.jmonkeyengine.org/legacy/doku.php/jme3:intermediate:appsettings

Sometimes when you don’t know how to do something, you can just open the javadoc and see if there is something similar. 5 seconds later:
http://hub.jmonkeyengine.org/javadoc/com/jme3/system/AppSettings.html#setUseInput(boolean)

If you don’t have the javadoc handy… then you may as well stop Java development right now. :wink:

Edit: do note that setting this to true means that your app can never take any user input… mouse, keyboard, or anything. If instead you just want to remove the default input mappings that’s a completely different thing. Otherwise, I guess your app is just a demo reel or something? (Can’t even hit escape to exit.)

@pspeed said: Sometimes when you don't know how to do something, you can just open the javadoc and see if there is something similar. 5 seconds later: http://hub.jmonkeyengine.org/javadoc/com/jme3/system/AppSettings.html#setUseInput(boolean)

If you don’t have the javadoc handy… then you may as well stop Java development right now. :wink:

Edit: do note that setting this to true means that your app can never take any user input… mouse, keyboard, or anything. If instead you just want to remove the default input mappings that’s a completely different thing. Otherwise, I guess your app is just a demo reel or something? (Can’t even hit escape to exit.)

Well, I’m pretty n00b at using the JavaDoc. It’s hard for me to find stuff. Should I seriously just give up?

@coolman50544 said: Well, I'm pretty n00b at using the JavaDoc. It's hard for me to find stuff. Should I seriously just give up?

Its not easy to learn java, its not easy to learn coding games either, doing both at the same time is (from our experience) solely resulting in frustration in 90% of the cases.

@coolman50544 said: Well, I’m pretty n00b at using the JavaDoc. It’s hard for me to find stuff. Should I seriously just give up? Its not easy to learn java, its not easy to learn coding games either, doing both at the same time is (from our experience) solely resulting in frustration in 90% of the cases.

Man, who the heck said I was learning Java -_-. The thing is I’ve been coding in Java for a while by learning the syntax and some really important and common classes, learning OOP concepts, working with XML and other stuff. I just never had to use the JavaDoc, because I didn’t develop serious applications. I just followed exercises from my book.

Well at least you learned how to use JavaDoc now, thats a plus…

@coolman50544 said: Well, I'm pretty n00b at using the JavaDoc. It's hard for me to find stuff. Should I seriously just give up?

Well, you already knew you had to deal with the AppSettings class so I don’t know how much searching there was to do. So, yeah, if clicking on a link in a browser or pressing alt-f1 in the SDK and then skimming the page for “anything that might be user input related” is too hard then you probably should give up… or find someone to sit next to you and mentor you.

Being able to navigate javadoc is sort of fundamental to java development. Like being able to turn a page is fundamental to reading a book. Better to get familiar with it now and save yourself years of pain.

1 Like