Latesleeper 12 Posted August 24, 2014 (edited) To start off, I'm really looking forward to the pages of posts about the superiority of keyboards/mice, how could anyone think of playing this game with a controller, and "just stop it". Just know, I only did this to aggravate you and not make the playing experience more enjoyable for myself. Seriously, I'm doing it so you get so angry you can't eat or sleep. Posting how angry you are couldn't bring me more joy. With that out of the way, anyone else foolish, careless, reckless or stupid enough to attempt to play the game in this fashion :P , here's where I'm at and I'd love your feedback on how it could be improved. I posted this somewhere buried on another thread and thought it may be helpful for it to have it's own place. This started off as something simple, and gradually the script became more complicated as I began to learn a bit more about GlovePIE and add in additional functions. As of right now the Xbox 360 Controller should behave like this: Left Stick: Walk/Run, strafe, backRight Stick: Mouse (variable speed based on action like aiming or running around, adjustable)Y = vault or step-overX = Previous (mouse wheel)B = Next (mouse wheel)A = default actionRight Trigger = Left Mouse click (with rumble when hitting/shooting)Left Trigger = Zoom in, look down sights when double pulled (mouse speed slowed down)DpadUP = StandDpadRight = CrouchDpadDown = ProneDpadBack = Voice ChatStart = Toggle Gear (mouse speed slowed down)Back = BackRightShoulder = Toggle Weapon readyClick Right Stick = Toggle Free LookClick Left Stick = Toggle run/walk WHILE HOLDING LEFT SHOULDER DOWN:Y = ReloadtapX = Inventory slot 1tapA = Inventory slot 2tapB = Inventory slot 3holdX = Inventory slot 4holdA = Inventory slot 5holdB = Inventory slot 6Single Click DpadUP= Toggle single fire/rapid fireDouble Click DpadUP= Toggle headlampDpadLEFT = Lean/Evade LeftDpadRIGHT = Lean/Evade RightSingle click DpadDOWN = WaveDouble Click DpadDOWN = One finger WaveBack = Third Person/First Person toggleStart = Toggle Player List Pressing Left Shoulder, Right Shoulder, and A will toggle the Steam Overlay on/off (if you like to shop on Amazon while you play ;)) Start by downloading the newest version of GlovePIE, run the program and copy the following script:(unlike the more recent versions this is not resolution specific, it also does not contain some of the advancements of the later versions)/*Dayz control layout, some keyboard bindings must be changed in gameNew In Game Keyboard Binding Changes: Under Infantry Movement: Turbo --> B (this has been disabled, seemed wonky) Fast Forward 2xW --> G*/PIE.FrameRate = 120Hz//Left Stick NavigationKey.W = InRange(XInput.Joy1Y, .20,0.80) //walkKey.G = InRange(XInput.Joy1Y, .81,1.00) //run//Key.B = InRange(XInput.Joy1Y, .90,1.0) //Turbo is disabledKey.S = InRange(XInput1.Joy1Y, -1.0,-.30) //BackKey.A = InRange(XInput.Joy1X, -2.0,-.30) //LeftKey.D = InRange(XInput.Joy1X, 0.30,2.00) //Right//Aiming Control - Right Stick - different sensitivity settings if Aiming(slowest), Looking at Gear(slow), or Normal (fastest)if var.GearTog = True Mouse.DirectInputX = Mouse.DirectInputX + 15*deadzone(XInput1.Joy2X) Mouse.DirectInputY = Mouse.DirectInputY - 15*deadzone(XInput1.Joy2Y) elseif (var.aim = True) or (XInput.LeftShoulder and Xinput.RightShoulder) then Mouse.DirectInputX = Mouse.DirectInputX + 10*deadzone(XInput1.Joy2X) Mouse.DirectInputY = Mouse.DirectInputY - 10*deadzone(XInput1.Joy2Y) else Mouse.DirectInputX = Mouse.DirectInputX + 28*deadzone(XInput1.Joy2X) Mouse.DirectInputY = Mouse.DirectInputY - 28*deadzone(XInput1.Joy2Y)endif//Mouse Left and Right Buttons with rumble (rumble removed when looking at gear)mouse.LeftButton = XInput.RightTriggerif var.GearTog = False then if helddown (XInput1.RightTrigger, 400ms) then XInput.Vibration2 = .60 XInput.Vibration1 = .80 wait 80 ms XInput.Vibration2 = 0 XInput.Vibration1 = 0 wait 80 ms elseif helddown (Xinput1.RightTrigger, 5ms) then XInput.Vibration2 = 1.0 XInput.Vibration1 = .50 wait 100 ms XInput.Vibration2 = 0 XInput.Vibration1 = 0 wait 300 ms endifelseif var.GearTog= True then XInput.Vibration2 = 0 XInput.Vibration1 = 0endifmouse.RightButton = XInput.LeftTriggerif Helddown (XInput.LeftTrigger, 400ms) and (var.aim = False) then var.aim = True endifif Released (XInput.LeftTrigger) and (var.aim = True) then var.aim = False endif// Main Controlsif not XInput.LeftShoulder then Key.V = XInput.Y //vault or hop //Next if XInput.B then mouse.WheelDown = True wait 200 ms mouse.WheelDown = False endif //Previous if XInput.X then mouse.WheelUp = True wait 200 ms mouse.WheelUp = False endif Key.F = XInput.A // use default action Key.C = XInput.Up //stand up Key.Z = XInput.Down //prone Key.X = XInput.Right //crouch Key.CapsLock = XInput.Left //Voice Chat Key.BackSpace = XInput.Back //Back Key.Tab = XInput.Start //Gear Key.Spacebar = XInput.RightShoulder //Toggle Raised Weapon if released (XInput.Start) and (var.GearTog = False) then var.GearTog = True elseif released (XInput.Start) and (var.GearTog = True) then var.GearTog = False elseif released (XInput.Back) and (var.GearTog = True) then var.GearTog = False elseif released (XInput.RightShoulder) and (var.GearTog = True) then var.GearTog = False elseif released (XInput.LeftShoulder) and (var.GearTog = True) then var.GearTog = False endifendif//Left Shoulder Button holdif XInput.LeftShoulder and not XInput.RightShoulder then Key.R = XInput.Y //Reload if XInput.X then //Selects Inventory 1 by Tapping X or Inventory 4 by Holding X var.Xhold = false endif if Helddown (XInput.X, 200ms) then var.Xhold = True endif if var.Xhold = false and Released (XInput.X) then press key.One release key.One elseif var.Xhold = True and Released (Xinput.X) then press key.Four release key.Four endif if XInput.A then //Selects Inventory 2 by Tapping A or Inventory 5 by Holding A var.Ahold = false endif if Helddown (XInput.A, 200ms) then var.Ahold = True endif if var.Ahold = false and Released (XInput.A) then press key.Two release key.Two elseif var.Ahold = True and Released (Xinput.A) then press key.Five release key.Five endif if XInput.B then //Selects Inventory 3 by Tapping B or Inventory 6 by Holding B var.Bhold = false endif if Helddown (XInput.B, 200ms) then var.Bhold = True endif if var.Bhold = false and Released (XInput.B) then press key.Three release key.Three elseif var.Bhold = True and Released (Xinput.B) then press key.Six release key.Six endif Key.Q = XInput.Left //Lean/Evade Left Key.E = XInput.Right //Lean/Evade Right Key.F1 = SingleClicked (XInput.Down) //Wave Key.F4 = Doubleclicked (XInput.Down) // Flip Off Key.T = SingleClicked (XInput.Up) //toggle automatic weapon to single shot Key.L = DoubleClicked (XInput.Up) // headlights on/off Key.Enter = XInput.Back //Toggle View Key.P = XInput.Start //Player Listendif//toggle Walk or Runif Released (XInput.LeftThumb) and (Key.LeftControl = True) then Key.LeftControl = Falseelseif Released (XInput.LeftThumb) and (Key.LeftControl = False) then Key.LeftControl = Trueendif//Toggle Free Lookif Released (XInput.RightThumb) and (Key.Alt = False) then Key.LeftAlt = Trueelseif Released (XInput.RightThumb) and (Key.Alt = True) then Key.LeftAlt = Falseendif//Toggle Steam Overlayif XInput.LeftShoulder and XInput.RightShoulder then if XInput.A then Press Key.Shift Press Key.Tab Wait 50ms Release Key.Tab Release Key.Shift endifEndifSave it (so you can bring it up next time), click Run and go ahead and start playing. Before you jump into the game proper, you need to change two default keybindings in DayZ Standalone (also noted in the script). Turbo should be changed to B and Fast Forward should be changed to G. Turbo isn't enabled right now, it was behaving strangely when I began testing it. I've been tweaking and testing in an attempt to dial in the feel of everything to my preferences. I'll continue to post versions of the script as I move along. Paste any changes or tweaks that you've made (or would like to see). If you're familiar with GlovePIE and have ways to streamline the script, your feedback is welcome. Edited September 6, 2014 by Latesleeper 1 Share this post Link to post Share on other sites
Katana67 2907 Posted August 24, 2014 (edited) Holy cow! Looks pretty rad. But might be a bit over my proverbial tech pay-grade. That said, I've been missing the ol' Xbox controller since they (inadvertently or not) removed controller support. And, oddly enough, you'll find the KBM folks a lot less hostile if you don't include the long diatribe at the beginning. I used both KBM and a controller when it was supported. At the same time. Get on my level peasants. Edited August 24, 2014 by Katana67 Share this post Link to post Share on other sites
GunnyITA 107 Posted August 24, 2014 Does this things goes in conflict with BattlEye and give you a Global Ban? Share this post Link to post Share on other sites
Latesleeper 12 Posted August 24, 2014 Does this things goes in conflict with BattlEye and give you a Global Ban? No, all GlovePIE is doing is reading input from the Xbox controller and emulating a keypress. As far as the game is concerned, you're using the keyboard and mouse. Share this post Link to post Share on other sites
Latesleeper 12 Posted August 24, 2014 Holy cow! Looks pretty rad. But might be a bit over my proverbial tech pay-grade. That said, I've been missing the ol' Xbox controller since they (inadvertently or not) removed controller support. And, oddly enough, you'll find the KBM folks a lot less hostile if you don't include the long diatribe at the beginning. I used both KBM and a controller when it was supported. At the same time. Get on my level peasants.If you're missing the Xbox controller, give it a go and tell me what you think. I attempted to keep the layout as simple/logical as I could without missing any important keybindings. (most of what you need is available in the main controls, more "weapons-based" controls when you hold the left shoulder) My goal wasn't to rattle the KBM people, I've just noted in the other threads where using a controller was discussed I had to wade through pages of off-topic posts regarding how the idea was stupid/crazy. 1 Share this post Link to post Share on other sites
omgwtfbbq (DayZ) 1069 Posted August 25, 2014 It seems like X should be reload/interact and the up/down D-pad to simulate scroll wheel; the left bumper would modify up/down when held down. Share this post Link to post Share on other sites
soulfirez 901 Posted August 25, 2014 (edited) I was on of the peasants who while the game supported the xbox360 controller used its limited functionality with a xpadder profile loaded over the top to put 90% of the games functions onto the controller (everything except the hand gestures which id just use the KB for.) i found it quite relaxing playing in my leather recliner with controller in hand wireless KB next to me playing on my 65 inch led tv, was nice even being able to use the xbox headset to communicate with was almost as good as my 190 dollar pc headset lol which is not wireless hence back to the monitor for me. since its removal i have put my pc back in the study and connected back to my monitor lol i can play the game with either controller or KB seeing its not really a twitch shooter you dont really loose to much playing with a controller( plus when vehicles come in the controller is much better for driving and flying helicopters) generally the person who sees the player first wins if there is a gun fight so unless thats at cqb the controller did alright (and certainly was more comfortable for long runs in the wilderness.. Might give this a try (does the movement work as it use to with the games profile that the stick controlled the speed of your movement as in slight tilt forward walk tilt further jog full way forward run ? Edited August 25, 2014 by SoulFirez Share this post Link to post Share on other sites
Latesleeper 12 Posted August 25, 2014 It seems like X should be reload/interact and the up/down D-pad to simulate scroll wheel; the left bumper would modify up/down when held down.Well, the script can certainly be changed to do this. But, if you consider moving the the scroll wheel to the up/down on D-pad, you'll be removing your left thumb from the left stick to make this movement. This means that running (or any movement, possibly for your life) can't be done when you're scrolling options. DayZ is set up so that you can scroll through a list of option and select one with one finger (roll up on the mouse wheel, roll down on the mouse wheel, center click the mouse wheel) while still making commands with your left hand. I've tried to retain that function on the controller. X for previous, B for Next, A to Interact (like open/close a door). Also, doing this will displace the stance functions (Stand up = DpadUP, Crouch = DpadRIGHT, Prone = DpadDOWN). In most cases you will be stopped (there for, your left thumb is off the left stick) when you want to change stances (and available for use on the Dpad). I do agree that Interact/Reload should share the same button (more logical). Moving Reload to LeftSHoulder + A and retaining Interact to A is a better choice. That makes TapX=1, HoldX=4, TapY=2, HoldY=5,TapB=3, HoldB=6. On the other hand..... While proof reading this post it occurred to me this as a possibility, as it retains the "up/down" notion of the scroll wheel:X = InteractY = Scroll UpA = Scroll DownB = Vault/Step OverLeftShoulder + X = ReloadLeftShoulder + TapY = Inv. 1LeftShoulder + HoldY = Inv. 4LeftShoulder + TapB = Inv. 2LeftShoulder + HoldB = Inv. 5LeftShoulder + TapA = Inv. 3LeftShoulder + HoldA = Inv. 6ShoulderLeft + X = Reload Thanks for the feedback omgwtfbbq 1 Share this post Link to post Share on other sites
Latesleeper 12 Posted August 25, 2014 I was on of the peasants who while the game supported the xbox360 controller used its limited functionality with a xpadder profile loaded over the top to put 90% of the games functions onto the controller (everything except the hand gestures which id just use the KB for.) i found it quite relaxing playing in my leather recliner with controller in hand wireless KB next to me playing on my 65 inch led tv, was nice even being able to use the xbox headset to communicate with was almost as good as my 190 dollar pc headset lol which is not wireless hence back to the monitor for me. since its removal i have put my pc back in the study and connected back to my monitor lol i can play the game with either controller or KB seeing its not really a twitch shooter you dont really loose to much playing with a controller( plus when vehicles come in the controller is much better for driving and flying helicopters) generally the person who sees the player first wins if there is a gun fight so unless thats at cqb the controller did alright (and certainly was more comfortable for long runs in the wilderness.. Might give this a try (does the movement work as it use to with the games profile that the stick controlled the speed of your movement as in slight tilt forward walk tilt further jog full way forward run ? The left stick movement should behave like this:If you press it 0 - 80% of the way forward: you jog or walk, this can be toggled back and forth when you click the left stick inIf you jam it all the way forward: you sprint (this is one of the default keybindings you'll have to change) The Strafe Left, Strafe Right and Back movements have one speed so they work if you press the stick more than 30% in those directions. Having said this, if you look at the code you can tweak those numbers. If you find something that seems to function more smoothly, let us know. I've played around with them a bit (for some reason GlovePIE liked an illogical value of 200% over 100% for left and right) and have gotten to something that does what I expect it to do. I was playing with the "turbo" button, but seemed weird and left the character standing at times. I think it may be incorporated later with vehicle stuff (and all this is moot or it can be incorporated back in) Share this post Link to post Share on other sites
captain_finnish 134 Posted August 25, 2014 Meh. I just dont understand why would anybody want to play DayZ on PC with controller. Controller is for casual gaming, but this just looks like a huge pain. It is also a very big disadvantage compared to mouse and keyboard. I can just imagine the pain when you try to do inventory management :D Share this post Link to post Share on other sites
hombrecz 832 Posted August 25, 2014 (edited) Apart from gamepad being less straining for wrists, I would personally not play FPS with it due to low precision as compared to mouse.But hey, you are free to play with whatever controller you fancy, the worst that can happen is, that you will gimp yourself much and become an easy target :-). Btw since they announced console version, maybe they will put controller support back? edit: As Katana67 said, people tend to be less hostile, when you don't start your post with passive aggresive statements. Edited August 25, 2014 by Hombre Share this post Link to post Share on other sites
Latesleeper 12 Posted August 25, 2014 Meh. I just dont understand why would anybody want to play DayZ on PC with controller. Controller is for casual gaming, but this just looks like a huge pain. It is also a very big disadvantage compared to mouse and keyboard. I can just imagine the pain when you try to do inventory management :DUsing a controller under GlovePIE doesn't preclude you from using the mouse and keyboard. So, if you want to play most of the game with the controller, then when you want to manage some inventory using the mouse, you absolutely can. I have while testing this script, though I'm trying to tweak it in a way that you shouldn't have (that much). As for your statement about Controllers are for casual gaming, please consider all of the games for consoles and whether or not they are all casual. Share this post Link to post Share on other sites
Latesleeper 12 Posted August 25, 2014 (edited) Apart from gamepad being less straining for wrists, I would personally not play FPS with it due to low precision as compared to mouse.But hey, you are free to play with whatever controller you fancy, the worst that can happen is, that you will gimp yourself much and become an easy target :-). Btw since they announced console version, maybe they will put controller support back? edit: As Katana67 said, people tend to be less hostile, when you don't start your post with passive aggresive statements. What I intended to be a little humorous came off as passive aggressive to you. Not my intention. I'm hoping to avoid the entire thread devolving into people arguing over which is the superior way to play a video game (seems pointless to me). But on that topic: The Idea that you wouldn't play a FPS with a controller is interesting. I think that maybe it says something about your approach to this game in particular (this is only an observation, not a "right" or "wrong"). For me, I don't do all that much twitch shooting in this game (or haven't, that doesn't mean that won't change), I spend a lot of time wandering around and whacking zombies on the head with an axe. I don't consider it much of a FPS, there are far better examples of that genre to play (for console or PC) if I chose to. What the game is lacking a bit now, is some decent controller support, which I'm hoping to cultivate. I look at it like this. It's hard to argue that a device that was created for one purpose is better only because people have been using it for a long time (the resistance to change). Keyboards were designed to type text, mice to interact with an OS GUI. Gamers adopted them and became extremely adept at using them for gaming. But a gaming controller was designed to perform a very specific task. If the controller interacts with the game well enough, I think you can achieve a very precise level of control. Whether it meets your standards is up to you. I'm only hoping to help progress it. Edited August 25, 2014 by Latesleeper Share this post Link to post Share on other sites
Latesleeper 12 Posted August 25, 2014 (edited) Edited: Cleaning Thread Edited September 6, 2014 by Latesleeper Share this post Link to post Share on other sites
captain_finnish 134 Posted August 25, 2014 Using a controller under GlovePIE doesn't preclude you from using the mouse and keyboard. So, if you want to play most of the game with the controller, then when you want to manage some inventory using the mouse, you absolutely can. I have while testing this script, though I'm trying to tweak it in a way that you shouldn't have (that much). As for your statement about Controllers are for casual gaming, please consider all of the games for consoles and whether or not they are all casual.I dont hate controllers, infact I have one and I play racing games with it (sometimes single player games too like Far Cry 3). Just wanted to point out that it is not worth it to use controller since there is no advantage when using controller in DayZ. DayZ is not made for controllers. I can somehow see it to be better option if you play on couch with TV, but still you get huge disadvantage. Share this post Link to post Share on other sites
hombrecz 832 Posted August 25, 2014 I look at it like this. It's hard to argue that a device that was created for one purpose is better only because people have been using it for a long time (the resistance to change). Keyboards were designed to type text, mice to interact with an OS GUI. Gamers adopted them and became extremely adept at using them for gaming. But a gaming controller was designed to perform a very specific task. If the controller interacts with the game well enough, I think you can achieve a very precise level of control. Whether it meets your standards is up to you. I'm only hoping to help progress it. I don't know why every gamepad defender uses "twitch" shooters when talking about mouse+keyboard combo. The thing is, M+K is lot more precise, atleast to my experience. I owned Xbox 360 for over 2 years, so I had plenty of time to test it myself.While I liked gamepad for sports, car games, beat em ups etc, I totally dislike that for FPS. Reason? The precision, as I've already mentioned. When I want to make headshot, I do not want to fight with the controller, I want to use it instead. I played Red Dead Redemption, SUPERB game, would love it to be ported to PC, enjoyed every second of it.Still when I remember me playing it, there were lots of moments where I simply fought the gamepad instead of just fighting the enemies. Then again it might be just me right? Maybe some folks are so agile as to achieve similar results with gamepad as with m+k combo. When talking about precision I find it rather hard to argue as well. I believe it was proven beyond shadow of a doubt, that M+K combo provides a lot more precise aiming.So for me m+k is not just about "twitch" shooters, it's about precision and fluid gameplay. Btw if you played a lot on consoles you probably must have noticed, that almost every shooting game, be it 1st or 3rd person one, had some kind of aim assist.Yes, you could turn it off, but it was there and mostly activated on default. To me this is another sign of gamepad being considered as not the best controller for shooters, not that I need any, as I'm fine with just my own experience. But again, I respect that some folks want to play everything on gamepad. If there is no autoaim, that would help them in PC multiplayer games, I have zero problem with that. 1 Share this post Link to post Share on other sites
captain_finnish 134 Posted August 25, 2014 Btw if you played a lot on consoles you probably must have noticed, that almost every shooting game, be it 1st or 3rd person one, had some kind of aim assist.Yes, you could turn it off, but it was there and mostly activated on default.Yep. GTA Online is almost unplayable because of it. People can shoot you with laser accuracy while you drive very fast past them. 1 Share this post Link to post Share on other sites
Latesleeper 12 Posted August 25, 2014 Finnish Sniper & Hombre: You both have some good points. I think maybe I'm just more familiar with a gamepad and that's why I prefer it. I can't find any keys on the keyboard unless both of my hands are on home row (muscle memory from typing). Yes, using a mouse is more accurate, but I suffer drastically on the keyboard hand. The goal of the thread isn't to convert anyone just to give options (and hopefully good ones) to those who like a gamepad. I have tried this and it's been mentioned in other threads, there's a weird hybrid option. Play with the gamepad in your left hand and use the mouse in your right. DayZ is set up right now that it accepts inputs from the controller, keyboard, and mouse simultaneously. So you can hop back and forth or use a mix of both (if the controller is set up that way). If anyone has an interest in playing that way, I can rewrite and post the script. Share this post Link to post Share on other sites
captain_finnish 134 Posted August 25, 2014 Finnish Sniper & Hombre: You both have some good points. I think maybe I'm just more familiar with a gamepad and that's why I prefer it. I can't find any keys on the keyboard unless both of my hands are on home row (muscle memory from typing). Yes, using a mouse is more accurate, but I suffer drastically on the keyboard hand. The goal of the thread isn't to convert anyone just to give options (and hopefully good ones) to those who like a gamepad.I have tried this and it's been mentioned in other threads, there's a weird hybrid option. Play with the gamepad in your left hand and use the mouse in your right. DayZ is set up right now that it accepts inputs from the controller, keyboard, and mouse simultaneously. So you can hop back and forth or use a mix of both (if the controller is set up that way). If anyone has an interest in playing that way, I can rewrite and post the script.I do hope that somebody finds your post helpful. 1 Share this post Link to post Share on other sites
Latesleeper 12 Posted August 25, 2014 (edited) Edited: Cleaning Thread Edited September 6, 2014 by Latesleeper Share this post Link to post Share on other sites
Latesleeper 12 Posted August 26, 2014 (edited) Because of the length of the script, I'll be editing and placing updated versions here. All other versions (except the earliest) have been deleted from this thread. Here is the current layout for 1920 x 1200 resolutions (YMMV by using this script with resolutions other than 1920 x 1200).This script is designed to lump together some mouse movements under certain circumstances. In most cases, it will automatically move the mouse to the place where you'll logically want it next. For Example while looting a room: stand near your item, after clicking start to open your gear the mouse will automatically be hovering over the first slot in the Vicinity Area, pull the left trigger and the mouse automatically moves over to the right and down a bit to highlight the first option, pulling the right trigger places it in your inventory. In total it's three button moves: Start, Left Trigger, Right Trigger (never manually moving the mouse). The speed of the rightstick is adjusted under different circumstances: When running around, it's fairly fast (you can also increase or decrease this value), while in your gear, it's slower (also adjustable), and it's even more precise when you're aiming (adjustable). Remember to adjust for both values X and Y (horizontal and vertical) If your rightstick needs some deadzone adjusting because it drifts a bit you can uncomment the debug options and determine what your new settings should be from within GlovePIE. Post questions and I'll do my best to answer them./*Dayz control layout, some keyboard bindings must be changed in gameNew In Game Keyboard Binding Changes: Under Infantry Movement: Turbo --> B (this has been disabled, seemed wonky) Fast Forward 2xW --> U Hold Breath RMB --> OChange Date 09-06-2014 13:30*/PIE.FrameRate = 120Hz//Left Stick NavigationKey.W = InRange(XInput.Joy1Y, .20,0.80) //walkKey.U = InRange(XInput.Joy1Y, .81,1.00) //run//Key.B = InRange(XInput.Joy1Y, .90,1.0) //TurboKey.S = InRange(XInput1.Joy1Y, -2.0,-.30) //BackKey.A = InRange(XInput.Joy1X, -2.0,-.30) //LeftKey.D = InRange(XInput.Joy1X, 0.30,2.00) //Right//Aiming Control - Right Stick - different sensitivity settings if Aiming(slowest), Looking at Gear(slow), or Normal (fastest)//debug = deadzone(XInput1.Joy2X)//debug = deadzone (XInput1.Joy2Y)If deadzone(XInput1.Joy2X) > .01 or < -.01 then var.MouseMoveX = TrueElseif deadzone(XInput1.Joy2X) < .01 or > -.01 then var.MouseMoveX = FalseEndifIf deadzone(XInput1.Joy2Y) > .01 or < -.01 then var.MouseMoveY = TrueElseif deadzone(XInput1.Joy2Y) < .01 or > -.01 then var.MouseMoveY = FalseEndifIf var.MouseMoveX = True then if var.GearTog = True then Mouse.DirectInputX = Mouse.DirectInputX + 12*deadzone(XInput1.Joy2X) //adjust for Gear Speed elseif (var.aim = True) or (XInput.LeftShoulder and Xinput.RightShoulder) then Mouse.DirectInputX = Mouse.DirectInputX + 3*deadzone(XInput1.Joy2X) //adjust for Aim Speed else Mouse.DirectInputX = Mouse.DirectInputX + 28*deadzone(XInput1.Joy2X) //adjust for movement speed endifEndifIf var.MouseMoveY = True then if var.GearTog = True then Mouse.DirectInputY = Mouse.DirectInputY - 12*deadzone(XInput1.Joy2Y) //adjust for Gear Speed elseif (var.aim = True) or (XInput.LeftShoulder and Xinput.RightShoulder) then Mouse.DirectInputY = Mouse.DirectInputY - 3*deadzone(XInput1.Joy2Y) //adjust for Aim Speed else Mouse.DirectInputY = Mouse.DirectInputY - 28*deadzone(XInput1.Joy2Y) //adjust for movement speed endifEndif//Mouse Pointer ShortCutsIf var.MouseVicinity = True then mouse.CursorPosX = 300 pixels mouse.CursorPosY = 200 pixels wait 10ms var.MouseVicinity = FalseEndifIf var.MouseCharacter = True then mouse.CursorPosX = 960 pixels mouse.CursorPosY = 360 pixels wait 10ms var.MouseCharacter = FalseEndifIf var.MouseDrop = True then mouse.CursorPosX = 1880 pixels mouse.CursorPosY = 1080 pixels wait 10ms var.MouseDrop = FalseEndifIf var.MouseGear = True then mouse.CursorPosX = 1460 pixels mouse.CursorPosY = 520 pixels mouse.WheelDown = true wait 5ms mouse.WheelDown = False wait 50ms var.MouseGear = FalseEndif//Mouse Left and Right Buttons with rumble and mouse actionsIf var.GearTog = False then if helddown (XInput1.RightTrigger, 400ms) then XInput.Vibration2 = .60 XInput.Vibration1 = .80 wait 80 ms XInput.Vibration2 = 0 XInput.Vibration1 = 0 wait 80 ms elseif helddown (Xinput1.RightTrigger, 5ms) then XInput.Vibration2 = 1.0 XInput.Vibration1 = .50 wait 100 ms XInput.Vibration2 = 0 XInput.Vibration1 = 0 wait 300 ms endif if var.recoil = false then mouse.LeftButton = XInput.RightTrigger elseif var.recoil = True and XInput.RightTrigger then press mouse.LeftButton wait 50 ms release mouse.LeftButton mouse.DirectInputX = mouse.DirectInputX - 12 mickeys //change to 6 for less compensation mouse.DirectInputY = mouse.DirectInputY + 24 mickeys //change to 8 for less compensation wait 200 ms endif mouse.RightButton = XInput.LeftTriggerEndif// No rumble when in gearIf var.GearTog = True then mouse.LeftButton = XInput.RightTrigger mouse.RightButton = XInput.LeftTrigger XInput.Vibration2 = 0 XInput.Vibration1 = 0 if Released (XInput.LeftTrigger) and mouse.CursorPosX < 700 and mouse.CursorPosY < 890 then var.MouseArea1 = True elseif Released (XInput.LeftTrigger) and mouse.CursorPosX > 700 and mouse.CursorPosY < 890 then var.MouseArea2 = True elseif Released (XInput.LeftTrigger) and mouse.CursorPosX > 700 and mouse.CursorPosY > 890 then var.MouseArea3 = True endifEndif//Define mouse shortcut areasIf var.MouseArea1 = True then press mouse.RightButton release mouse.RightButton wait 100 ms mouse.CursorPosX = mouse.CursorPosX + 30 pixels mouse.CursorPosY = mouse.CursorPosY + 15 pixels var.MouseArea1 = FalseEndifIf var.MouseArea2 = True then press mouse.RightButton release mouse.RightButton wait 100 ms mouse.CursorPosX = 1310 pixels mouse.CursorPosY = mouse.CursorPosY + 15 pixels var.MouseArea2 = FalseEndifIf var.MouseArea3 = True then press mouse.RightButton release mouse.RightButton wait 100 ms mouse.CursorPosX = 1310 mouse.CursorPosY = mouse.CursorPosY -72 pixels var.MouseArea3 = FalseEndif//Define states between aiming and not aimaing, holding breathIf Helddown (XInput.LeftTrigger, 400ms) and (var.aim = False) then var.aim = True wait 500 ms Key.O = TrueEndifIf Released (XInput.LeftTrigger) and (var.aim = True) then var.aim = False Key.O = FalseEndif// Main ControlsIf not XInput.LeftShoulder then if XInput.Y then //Vault/Hop by Tapping Y or "not bound" Holding Y var.Yhold1 = false elseif Helddown (XInput.Y, 300ms) then var.Yhold1 = True endif if var.Yhold1 = false and Released (XInput.Y) then press Key.V release Key.V elseif var.Yhold1 = True and Released (Xinput.Y) then //press Key.G //wait 500ms //release Key.G endif if XInput.B then //Next mouse.WheelDown = True wait 200 ms mouse.WheelDown = False endif if XInput.X then //previous mouse.WheelUp = True wait 200 ms mouse.WheelUp = False endif Key.F = XInput.A //default action //Define State between Gear and Not Gear If released (XInput.Start) and (var.GearTog = False) then var.GearTog = True var.MouseVicinity = True Elseif released (XInput.Start) and (var.GearTog = True) then var.GearTog = False Endif //Tab into Gear and not ALT TAB accidentally If XInput.Start then Key.LeftAlt = False Press Key.Tab wait 50 ms Release Key.Tab wait 200 ms Endif //Toggle Free Look If Released (XInput.RightThumb) and (Key.LeftAlt = False) then Key.LeftAlt = True elseif Released (XInput.RightThumb) and (Key.LeftAlt = True) then Key.LeftAlt = False Endif Key.Spacebar = XInput.RightShoulder //Toggle Raised Weapon //Modify Dpad when in Gear or Not Gear If var.GearTog = False then Key.Shift = XInput.Back //holding Back and pressing Start opens Steam Overlay Key.C = XInput.Up //stand up Key.Z = XInput.Down //prone Key.X = XInput.Right //crouch Key.CapsLock = XInput.Left //Voice Chat Elseif var.GearTog = True then if XInput.Up then var.MouseCharacter = True endif if XInput.Right then var.MouseGear = True endif if XInput.Down then var.MouseDrop = True endif if XInput.Left then var.MouseVicinity = True endif EndifEndif//Left Shoulder Button holdIf XInput.LeftShoulder and not XInput.RightShoulder then if XInput.Y then //Reload by Tapping Y or Throw Holding Y var.Yhold2 = false endif if Helddown (XInput.Y, 300ms) then var.Yhold2 = True endif if var.Yhold2 = false and Released (XInput.Y) then press Key.R release Key.R elseif var.Yhold2 = True and Released (Xinput.Y) then press Key.G wait 500ms release Key.G endif if XInput.X then //Selects Inventory 1 by Tapping X or Inventory 4 by Holding X var.Xhold2 = false endif if Helddown (XInput.X, 200ms) then var.Xhold2 = True endif if var.Xhold2 = false and Released (XInput.X) then press key.One release key.One elseif var.Xhold2 = True and Released (Xinput.X) then press key.Four release key.Four endif if XInput.A then //Selects Inventory 2 by Tapping A or Inventory 5 by Holding A var.Ahold2 = false endif if Helddown (XInput.A, 200ms) then var.Ahold2 = True endif if var.Ahold2 = false and Released (XInput.A) then press key.Two release key.Two elseif var.Ahold2 = True and Released (Xinput.A) then press key.Five release key.Five endif if XInput.B then //Selects Inventory 3 by Tapping B or Inventory 6 by Holding B var.Bhold2 = false endif if Helddown (XInput.B, 200ms) then var.Bhold2 = True endif if var.Bhold2 = false and Released (XInput.B) then press key.Three release key.Three elseif var.Bhold2 = True and Released (Xinput.B) then press key.Six release key.Six endif Key.Q = XInput.Left //Lean/Evade Left Key.E = XInput.Right //Lean/Evade Right Key.F1 = SingleClicked (XInput.Down) //Wave Key.F4 = Doubleclicked (XInput.Down) // Flip Off if SingleClicked (XInput.Up) then //toggle recoil assist //Key.T toggles single/rapid fire if var.recoil = False then var.recoil = True BeepAsterisk elseif var.recoil = True then var.recoil = False BeepHand endif endif Key.L = DoubleClicked (XInput.Up) // headlights on/off Key.Enter = XInput.Back //Toggle View Key.P = XInput.Start //Player ListEndif//toggle Walk or RunIf Released (XInput.LeftThumb) and (Key.LeftControl = True) then Key.LeftControl = Falseelseif Released (XInput.LeftThumb) and (Key.LeftControl = False) then Key.LeftControl = TrueEndif//Restart ScriptIf XInput.LeftShoulder and XInput.RightShoulder then if XInput.Back then BeepExclamation Chain ("C:\GlovePIE\Dayz_Standalone_Testing.PIE") endifEndif Edited September 6, 2014 by Latesleeper Share this post Link to post Share on other sites
Latesleeper 12 Posted August 27, 2014 (edited) Edited: cleaning thread Edited September 6, 2014 by Latesleeper Share this post Link to post Share on other sites
Latesleeper 12 Posted September 4, 2014 (edited) Edited: cleaning thread Edited September 6, 2014 by Latesleeper Share this post Link to post Share on other sites
Latesleeper 12 Posted September 4, 2014 I noticed that I'm only using the Back button in the Left Shoulder Hold state (changing from third/first person view). I think this opens some options up. I may end up moving the Steam Overlay to the Back Button, eliminating a three button press for it currently. It's also cleaner. 1 Share this post Link to post Share on other sites
d0pesen 17 Posted September 4, 2014 awesome work :D i will check it out. thx. Share this post Link to post Share on other sites