View Poll Results: Well, is it a good idea?

Voters
7. You may not vote on this poll
  • Brilliant!

    2 28.57%
  • Blasphemy!

    1 14.29%
  • Indifferent

    4 57.14%
Results 1 to 21 of 21

Thread: Are emulated inputs the answer for parity with controller users?

  1. #1
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)

    Lightbulb Are emulated inputs the answer for parity with controller users?

    With the current state of the game, analog nudging enables a lot of things that arenít possible to keyboard-only users and Iíd like to mend the disparity. Telling players to purchase and use a controller over what their accustomed to isnít a solution so I found an alternative since one hasnít been provided.

    And I didnít invent it! The racing, flying & farming simulator communities also found ways to translate input into their respective games of choice instead of purchasing [expensive] peripherals.

    So.. what is it?
    Mapping a movement on a virtual controller thatís available via keystroke.

    Hey! Isnít this cheating since there is a lack of nuance?
    The tilt-bob is there to detect if you were, as for nuance the technical aspect is there isnít much room for it in a 0.0333 [2 frame] window when dealing with keypresses in TPA, it is however possible for mouse and trackball to act as your nuanced input, however keyboard users wouldnít be inclinded to take their hands off the keyboard.

    I donít like easy special moves!
    Continue as you were, but if you happen to like arbitrary self-imposed rules you could replace keyboard nudging with softer emulated nudges, limit the number of times theyíre used resulting in a Ďmore reaslisticí experience.

    So before I layout the details what are your thoughts? Does this bring keyboard up to par with the controller, close to it atleast? As a keyboard player would you want to Head2Head a controller user?

    -A controller user trying to help out the keyboard players

  2. #2
    Senior Member invitro's Avatar
    Join Date
    May 2012
    Location
    N/A
    Posts
    2,336
    My Devices
    PC
    Mentioned
    42 Post(s)
    Tagged
    0 Thread(s)
    I'd like to be able to perform a "soft" nudge with keyboard, sure. I'd like to be able to play anybody head 2 head, controller or not, except maybe on Big Shot or El Dorado.

    No vote yet because I don't know what your idea is...

  3. #3
    Senior Member
    Join Date
    Jun 2012
    Location
    Seattle
    Posts
    907
    My Devices
    PS4 X1 Vita
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    I'm interested I suppose although I don't think the nudging is a big deal.
    I'm curious what you're thinking. Autohotkey scripting? If it is super simple to implement and doesn't interfere with my cab I might do it.

  4. #4
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    So far what I have is a script thats run by a program that interprets keyboard inputs that outputs a DirectInput value, then that DirectInput value is converted into an XInput value which the game recognises. It isn't run or written for AHK but likely could easily be ported to it.

    At the moment WASD would be your nudging directions and if you held space while pressing WASD then a modifier changes the value sent, currently you can set it below 100% then modify it further or the reverse, always soft unless you hold the spacebar.

  5. #5
    Senior Member
    Join Date
    Jun 2012
    Location
    Seattle
    Posts
    907
    My Devices
    PS4 X1 Vita
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by relaxation View Post
    So far what I have is a script thats run by a program that interprets keyboard inputs that outputs a DirectInput value, then that DirectInput value is converted into an XInput value which the game recognises. It isn't run or written for AHK but likely could easily be ported to it.

    At the moment WASD would be your nudging directions and if you held space while pressing WASD then a modifier changes the value sent, currently you can set it below 100% then modify it further or the reverse, always soft unless you hold the spacebar.
    Sounds cool, not sure how well it would translate to the cabinet though.

  6. #6
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Metalzoic View Post
    Sounds cool, not sure how well it would translate to the cabinet though.
    Does your cab already have nudging support for other games, like an accelerometer? a trackball? Perhaps a suspended mouse?

    maybe a pedal, dance, balance board peripheral.., some players look like they already dance at the machines
    oh maybe a trackpad mounted on the side, nudge via swipe of a finger

    I believe wiimotes and other IR tracking stuff might work so suspend those in the cab?
    Last edited by relaxation; 10-12-2015 at 06:38 PM. Reason: trackpad sounds neat

  7. #7
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    Here's a visual sample (had two modifier keys), not sure on the status of if KB users could diagonal nudge but you could configure it that way if you don't want straight left/right or use a modifer key to make them diagonal.

    I played Xenon earlier on keyboard, wasn't too bad. Little confusing at first having to flip and nudge with the left hand (compared to an analog stick). the third and pinky finger on LeftShift, WASD with the middle and pointer & modify with a thumb on Space or LeftAlt

    I'll look into cab stuff soon, do not have a bluetooth reciever to test the Wiimotes(22USD used at gamestop) accelerometer.

    gameplay here time of this posting it's still processing, shouldn't take too long
    Last edited by relaxation; 10-13-2015 at 07:35 PM. Reason: gameplay

  8. #8
    Senior Member Pantah010's Avatar
    Join Date
    Jan 2013
    Location
    Holland
    Posts
    113
    My Devices
    Cabinet
    Mentioned
    14 Post(s)
    Tagged
    0 Thread(s)
    I would realy like to see a softer nudge on the keys input also.
    Already started a simular thread before, hope your solution will work good on a cab.

    Nudge - Analog vs Digital fair? (<-- old thread)


    Cheers
    Channels: Twitch / YouTube

  9. #9
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    Here's the instructions:


    Anyone is welcome to port it to AHK and post it here, the program I'm using has a DIY vr/headtracking crowd behind it so Wii/Android/iStuff have plugins that may allow me to access&interpret their accelerometers, IR tracking may have too much latency for this application but I could be wrong. vpforums may help you cab people out, they've been doing this for at least 6 years before me with other tools but I've shown you.. I hope.. how to take their solutions and wrap it up in a way TPA would accept it.

    In other terms to explain the tools and their use: vJoy is the vessel, FreePIE is the engine and x360ce is the cloaking device
    Last edited by relaxation; 10-18-2015 at 01:47 PM. Reason: analogy

  10. #10
    Senior Member
    Join Date
    Jun 2012
    Location
    Seattle
    Posts
    907
    My Devices
    PS4 X1 Vita
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    You might want to add a warning to your instructions about VJoy. It is a useful program, however many programs can conflict with it.

    For example AAE emulation and other emulators will crash if you have the VJoy drivers enabled. Many games will not work right (or work at all) with VJoy enabled such as Broforce, Street Fighter IV, Shank, Expendabros and a bunch of others that I've run across myself. On the flip side some games need VJoy to work with a keyboard, or in an arcade cabinet, like Mortal Kombat X and Injustice.

    It doesn't need to be unintstalled, you just disable it from Device Manager under Human Interface Devices when not using it to avoid conflicts.

  11. #11
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    To be clear there are two virtual controller solutions that use the letters "vjoy", one is vJoy(sourceforge) the other is VJoy(headsoft).

    After you mentioned it I just checked Broforce and there was a pulling to the left problem on the world campaign map, until I went into gamepad options and cleared it. later on I remapped Broforce and it moved on the map fine but not the characters, then checked Ultra Street Fighter IV and it didn't have an option to clear mappings but from what I could test it didn't interfere

    Do those other games have an option to clear gamepad bindings? if you had a gamepad.. you wouldn't need this setup I would image.

    thanks for the possible heads-up for those who play other games in the post below, I haven't really played anything else outside of pinball in some time.
    Last edited by relaxation; 10-18-2015 at 09:44 PM.

  12. #12
    Senior Member
    Join Date
    Jun 2012
    Location
    Seattle
    Posts
    907
    My Devices
    PS4 X1 Vita
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    I forgot their were two different programs with the same name. I can't remember which is the problem one. I believe it uses a green icon though.
    I just mentioned it just in case someone downloads it and has issues because they could lose hours upon hours trying to troubleshoot what's wrong. This way they already know what to do if they have a problem.

  13. #13
    Senior Member Pantah010's Avatar
    Join Date
    Jan 2013
    Location
    Holland
    Posts
    113
    My Devices
    Cabinet
    Mentioned
    14 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by relaxation View Post
    Here's the instructions:
    Hi, i tried this, works great! but the nudge is a bit to weak.
    So i messed arround with the script, what value is 100% or 75% etc?
    Can this auto start with windows?
    Thanx
    Last edited by Pantah010; 11-08-2015 at 10:54 AM.
    Channels: Twitch / YouTube

  14. #14
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Pantah010 View Post
    Hi, i tried this, works great! but the nudge is a bit to weak.
    So i messed arround with the script, what value is 100% or 75% etc?
    Can this auto start with windows?
    Thanx
    Thanks for trying it out! I'll look into autostarting it* or just porting to AHK since a lot of people use that (I did too at one point).

    Code:
    #soft logic
    if not keyboard.getKeyDown(N2_key):
    pressed = .6
    if keyboard.getKeyDown(N2_key) and pressed > 0:
    pressed = 1
    if keyboard.getKeyDown(N3_key) and pressed > 0:
    pressed = .8
    In english:
    If you aren't pressing the [N2_key] space bar it's only doing 60% (max value * .6).
    If you're pressing the space bar its 100% (max value * 1)
    If you're pressing the [N3_key] left alt key it's 80% (max value * .8).

    So you could change these values to anything, like .55, .946 or .64334 to essentially get any xx.x% strength nudge you desire.

    *Copy your script to the same folder as FreePIE or use its full location when making a shortcut to FreePIE like so...

    Use this shortcut manually, task scheduler or whatever and it'll launch the quoted script and /r starts it.
    Last edited by relaxation; 11-08-2015 at 12:57 PM.

  15. #15
    Senior Member Pantah010's Avatar
    Join Date
    Jan 2013
    Location
    Holland
    Posts
    113
    My Devices
    Cabinet
    Mentioned
    14 Post(s)
    Tagged
    0 Thread(s)
    Thanx, really happy with this!
    Now to revisit all tables with this softer nudge (got it at .75)
    I recommend this for cabs with digital nudge!

    Cheers
    Channels: Twitch / YouTube

  16. #16
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    I came across an oversight on my part, there's an important subject regarding the Invert Nudge option inside the game and I made the FreePIE script with that turned on but I believe my controller had up&down inverted in x360ce so I never noticed up and down got inverted as well until I was trying to get AHK stuff going.

    If you're not getting the intended behavoir... Keep Invert Nudge in mind if you're setting this up, you can turn it off and swap the axises math stuff yourself in the script or mess about in x360ce for the same purpose when selecting inverted axis <number>.
    Last edited by relaxation; 11-11-2015 at 08:57 AM. Reason: clarification

  17. #17
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    If you really need AHK support, which I'd advise against, this is what I could come up with so far for keyboard-only players.
    You'll need to create a \Lib folder in ...\Program Files\AutoHotkey and put the CvJoyInterface.ahk file there in order for below to work.
    Code:
    ;Emulated controller input for keyboard-only players of Pinball Sims
    #SingleInstance, force
    #include <CvJoyInterface>
    ; shortening terms
    vJ := new CvJoyInterface()
    mS := vJ.Devices[1]
    pos := vJ.PercentTovJoy(100)
    rest := vJ.PercentTovJoy(50)
    neg := vJ.PercentTovJoy(0)
    posmod := vJ.PercentTovJoy(80)
    negmod := vJ.PercentTovJoy(20)
    
    ; starting neutral state
    mS.SetAxisByName(rest,"x")
    mS.SetAxisByName(rest,"y")
    mS.SetAxisByName(rest,"z")
    mS.SetAxisByName(rest,"rx")
    mS.SetAxisByName(rest,"ry")
    mS.SetAxisByName(rest,"rz")
    
    ; modified power hotkeys via WASD
    ~*w::
    KeyWait, w, D
    	mS.SetAxisByName(rest,"x")
    	mS.SetAxisByName(posmod,"y")
    KeyWait, w
    	mS.SetAxisByName(rest,"y")
    	return
    ~*a::
    KeyWait, a, D
    	mS.SetAxisByName(rest,"y")
    	mS.SetAxisByName(negmod,"x")
    KeyWait, a
    	mS.SetAxisByName(rest,"x")
    	return
    ~*s::
    KeyWait, s, D
    	mS.SetAxisByName(rest,"x")
    	mS.SetAxisByName(negmod,"y")
    KeyWait, s
    	mS.SetAxisByName(rest,"y")
    	return
    ~*d::
    KeyWait, d, D
    	mS.SetAxisByName(rest,"y")
    	mS.SetAxisByName(posmod,"x")
    KeyWait, d
    	mS.SetAxisByName(rest,"x")
    	return
    	
    ; full power hotkeys via WASD with Alt held down
    ~*!w::
    KeyWait, w, D
    	mS.SetAxisByName(rest,"x")
    	mS.SetAxisByName(pos,"y")
    KeyWait, w
    	mS.SetAxisByName(rest,"y")
    	return
    ~*!a::
    KeyWait, a, D
    	mS.SetAxisByName(rest,"y")
    	mS.SetAxisByName(neg,"x")
    KeyWait, a
    	mS.SetAxisByName(rest,"x")
    	return
    ~*!s::
    KeyWait, s, D
    	mS.SetAxisByName(rest,"x")
    	mS.SetAxisByName(neg,"y")
    KeyWait, s
    	mS.SetAxisByName(rest,"y")
    	return
    ~*!d::
    KeyWait, d, D
    	mS.SetAxisByName(rest,"y")
    	mS.SetAxisByName(pos,"x")
    KeyWait, d
    	mS.SetAxisByName(rest,"x")
    	return
    I tried loops, while getkeystates etc to get the line count down but those didn't work as reliably when striking the hotkey repeatedly at a quick pace. Couldn't bind the spacebar either when an astrisk is in use which is required because you may have a flipper engaged.

    Currently I do not see AHK providing emulated nudge capabilities to cabs via accelerometer with this CvJoyInterface.. at least not in a way I understand from their SDK

  18. #18
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    Looks like a new avenue has opened today for FreePIE without the vJoy or x360ce requirements but requires the 360 driver and ScpDriver instead.
    the vJoy dev was looking at emulating xinput stuff on the driver level too, but I think some kind of driver install, vJoy or ScpDriver, will always be a requirement
    Does anyone have prior experience they'd like to share with the ScpDriver being used as an xinput wrapper? I don't have PS3&4 controllers.

    Confirming that it works: proof
    requiring me to build the dll myself was a pita, here just go download VS2015, which is 5GB, to build this 21KB dll file.
    Checked TPA, FX2 and Broforce(reset your gamepad binds) and it works.. after I removed the x360ce files from their directories
    Last edited by relaxation; 11-14-2015 at 11:36 AM. Reason: game tested

  19. #19
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    So I'm toying with the idea of an articial tilt-bob, at the moment I'm only trying to mimic the ingame meter.

    Any thoughts or ideas on this subject?

  20. #20
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    While in the shower I was going over various ways people have done their nudge input since I think the accelerometer method is prohibitive in cost or complexity.

    I didn't like the IR-wiimote method because it would wobble, I was just thinking the wiimote-accelerometer too would wobble and trying to think of a way to implement a digital deadzone, then I thought how would I deaden the wobble physically.. and it came to me: the hanging-dimes-off-a-mounted-controllers-analog-stick weren't there to push the stick from a nudge.. they were there to hold the analog stick in place while the table moved. I may play with this idea HOWEVER..

    Later tonight I found out people disassembled FreestylePro controllers, mounted them, and used it as an analog input device.. now recently in that thread this project was linked to and basically it's a program to run on this [15USD] accelerometer which then can be seen as a USB gamepad and it looks like someone has already used x360ce to wrap it and have it work for TPA/FX2.. so Cab players seem covered with an inexpensive product that doesn't come with problems like a wiimote(batteries/wake issues).


    Different topic, Custom tilt-bob
    I thought I wanted to mimic the in-game meter but I looked at how VP/FP had their nudge systems in place and they're all just you can only do z-value or y-value over x-time. Then I wanted to mimic the behavior of a 2D pendulum, complete with input methods adding/subtracting to its motion based on the x-axis.. with a copy of that also working for the y-axis for a 3D space representation of a tilt-bob. Turns out the idea is easier than knowing how to implement it.

    The idea was it read your inputs, applied it to the v. pendulum and then do input denial when you go above your virtual space allowance.
    Virtual space allowance is a fancy way of saying one of the parameters is a virtual ring, the ring being the tilt sensor, .. on a physical machine think of the bob as a tear, as a tear the shape gets bigger further down right? so the difficulty of a machine is decided where the tear is placed inside the ring (higher or lower).. instead of this setup we would determine the ring size instead of the physical parameters of the tear since it's software.

    This is basically a 3rd-party difficulty setting you could use for possibly all your pinball games.

    Would there be any interest in funding this idea since I'm not qualified?
    I'd perfer this to run in FreePIE, making the source free to the public to edit

    A future problem, if it came to be, would be how to scale the ring to match real machines and then scaling real force to virtual space.. and of course knowing which table we're playing
    Last edited by relaxation; 01-18-2016 at 11:48 PM.

  21. #21
    Senior Member
    Join Date
    Oct 2015
    Location
    Minneapolis
    Posts
    561
    My Devices
    PC
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    Emulated Inputs for keyboard-only Pinsim players: xinput edition

    Tools: Microsoft 360 Controller Drivers & FreePIE
    Downloads: goo.gl/uLRwBB (Driver), goo.gl/FKzF6F (FreePIE), & goo.gl/K0MoFC (FreePIE plugin)

    Install the Xbox360 drivers

    Install FreePIE
    Copy the downloaded XOutputPlugin.dll to its ...\FreePIE\plugins directory
    #optional: You maybe required to Ďunblockí this dll by browsing its file properties
    copy script @ goo.gl/X3KQpk
    paste, save it, run script

    Press WASD to confirm output in..
    control panel\devices and printers\Xbox 360 Controller for Windows
    or
    look at the Watch tab at the bottom of the FreePIE program to see value changes
    This is mainly geared towards analog nudging output, I can come up with a plunger control scheme at a later date by request.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •