Improved Input System

Marked for deletion
Will this work on a usb - controller for pc?
usb-controller?

If you're referring to an Xbox360 or PS3 controller being plugged in via usb; yes they will work.

If you're referring to some other controller type; it may work; and if so it'd most likely be using the PS3 Controller Mapping.
I have a logitech usb pc controller and the ps3 or xbox 360 controller doesn't work for it.
 
do i need to use a xinput dll?
(xinput1_3.dll and call it xinput9_1_0.dll)

The idea was taken from this topic in the steam forums

http://forums.steampowered.com/forums/showthread.php?t=1992159
Wait, none of them work? Or just the Logitech Controller?

I'd be far more interested to know what Operating System you're using. XInput came with the DLLs I provided so that shouldn't be an issue.

That said, if it's not working, it's not working. I don't have a Logitech Controller of my own to test with.

One more thing, place this code snippet somewhere in your scripts section. It'll tell you if it's detecting your controller. You'll need to Allow it to show the console though (option is in the Game Menu of the editor).

Code:
class Scene_Base  alias upinput update  def update    upinput    p("XboxControllerConnected = " + Input.xbox360_input.connected?.to_s +      "     PS3ControllerConnected = "  + Input.ps3_input.connected?.to_s)  endend
What are the supported operating Systems? I tried it on Windows 8.1 and it said the dll was missing.
If a dll is missing, you could possibly download it. Just beware on where you get it,
This would be awesome but just can't get it to work. For some reason it just doesn't recognize the controller. Without this script the Xbox 360 controller works fine, with the script the controller stops working. I added the script and put both of the .dll to system folder. Any ideas what could be wrong?
This would be awesome but just can't get it to work. For some reason it just doesn't recognize the controller. Without this script the Xbox 360 controller works fine, with the script the controller stops working. I added the script and put both of the .dll to system folder. Any ideas what could be wrong?
Yea, likewise. I double checked all the issues that the error message comes up with (Having DX installed, the dll, etc.), and it's just not going. I'm using Windows 7 Ultimate.
This is the same problem I'm having for both 360 and PS3 controllers - even when the DLL seems to be in the right place, it just can't load the DLL. By removing the scripted error message, I get a Runtime Error, LoadLibrary, regarding IsConnected = Win32API.new('System/ps3_controller.dll', 'ConnectedController', '', 'n'), or similar for the 360 controller line. I think it's applied to all the Win32API calls though, not just the "is this connected" check.

I'm also using Windows 7, Home Premium.

I also get an error with evented button checks. I have a parallel process that checks if the C button (keyboard Z) is pressed, and get this error:

Line 1484, NoMethodError occurred.

Undefined method [] for nil:NillClass.

The line is return @@input_mapping[sym][😛c_keyboard].any?{|k| @@keyboard_keys.press?(k)}
This is the same problem I'm having for both 360 and PS3 controllers - even when the DLL seems to be in the right place, it just can't load the DLL. By removing the scripted error message, I get a Runtime Error, LoadLibrary, regarding IsConnected = Win32API.new('System/ps3_controller.dll', 'ConnectedController', '', 'n'), or similar for the 360 controller line. I think it's applied to all the Win32API calls though, not just the "is this connected" check.

I'm also using Windows 7, Home Premium.

I also get an error with evented button checks. I have a parallel process that checks if the C button (keyboard Z) is pressed, and get this error:

Line 1484, NoMethodError occurred.

Undefined method [] for nil:NillClass.

The line is return @@input_mapping[sym][😛c_keyboard].any?{|k| @@keyboard_keys.press?(k)}
Try this:

Spoiler
#------------------------------------------------------------------------------|# * Edit module: Input |#------------------------------------------------------------------------------|module Input class << self # Added to map the event key codes to their corresponding key symbols Event_Key_Codes = { 2 => 😀OWN, 4 => :LEFT, 6 => :RIGHT, 8 => :UP, 11 => :A, 12 => :B, 13 => :C, 14 => :X, 15 => :Y, 16 => :Z, 17 => :L, 18 => :R } #--------------------------------------------------------------------------| # Alias method: press? | #--------------------------------------------------------------------------| alias press_fix? press? def press?(sym) # Rewritten to convert event key codes to corresponding key symbols first press_fix?(sym.is_a?(Integer) ? Event_Key_Codes[sym] : sym) # end # press? end # selfend # Input
The root cause is the rewritten press? always assumes all of its callers will only pass key symbols to it, but command_111 in fact passes key symbol code(an integer corresponding to its key symbol) instead.
Added the above Module, Downloaded Direct X, and I have the newest Windows 8 version Laptop. Yet I keep getting;

Screenshot (35).png

Screenshot (36).png

_________________

Don't get me wrong, I turn the controller bits to false, it works perfectly. But when I want to try the controller bits, I get that error [and the Dll's are saved in the system folder]. So ... should I just keep the Controller options as set to false so I  can use the program, or is there a way around this error? 
Hello Mods,

Can I ask for this thread to be deleted?

This script only works on certain kinds of PCs. I did have plans to try and improve compatibility with other operating systems but never got around to it.

As a result of not improving script performance. This script is only dead weight and is likely giving a false sense of hope to whoever is looking for such a script and coming across this.

As a result of this, I think it's better to just remove the thread.



Thanks
Marked for deletion
DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE DELETE

ehm... sorry, I apologize, I couldn't resist... 🙁
hope you guys don't mind since it's going to be... DLETEEEEEEED
We don't delete topics, so allow me to close this one for you.

Closed at OP's request

Original thread: https://forums.rpgmakerweb.com/threads/improved-input-system.21414/