This topic has been locked
swift_wrath Nov 19, 2013 @ 3:43am
GlovePIE Scripting
i recently downloaded the steam version of kotor and wanted to use a controller. i naturally went to the glovepie program that i use any other time i want to emulate a keyboard/mouse with a controller. the kotor 1 and 2 versions steam have available though are of course the original pc release versions w/ little to no changes made. because of this i still had to leave some kind of mouse element to the emulation because i otherwise would not be able to utilize the ability to cycle through the options of certain actions. such as being able to choose power/flurry attack as opposed to default. this was no big deal as ive made a decent layout that is yet not fully tested in the game for a number of reasons. the biggest of course being that though ive gotten the game "fixed" enough to make it through the opening developer/publisher screens it still crashes if i tab away to another program. no big deal but switching back and forth swiftly is not doable. upon my last "jump" into the game while running the glovepie script i discovered that my 360 controller is experiencing the fairly common problem of the analog going off in different directions as it sees fit. this can occur irregardless of how well you take care of your analogs. in this case its specifically the x axis of the right analog. so with the mouse function of the game tied to my right stick im having a very difficult time testing my new control scheme. i wanted to write a script to counter this but i dont know the specific term that would be used for it and cant seem to find anything in web forums. the best term i could think of is deadzone, but glovepie unfortunately reads this as the sensitivity of how fast/slow the mouse moves. DOES ANYBODY KNOW THE CORRECT TERM I NEED TO USE TO CORRECT THE PRESSURE REQUIRED ON THE INPUT ANALOG BEFORE THE OUTPUT RESPONDS?
below ive included the script i have so far, and its currently mapped to the default key mapping of kotor just in case its of any relevance...


//Left Stick – Movement
keyboard.W = XInput1.Joy1Y > 0.2
keyboard.S = XInput1.Joy1Y < -0.2
keyboard.A = XInput1.Joy1X < -0.2
keyboard.D = XInput1.Joy1X > 0.2

// Right Stick – Mouse Pointer
Mouse.DirectInputX = Mouse.DirectInputX + 10*deadzone(XInput1.Joy2X)
Mouse.DirectInputY = Mouse.DirectInputY + 10*deadzone(XInput1.Joy2Y)

// 360 Bumpers
keyboard.Q = XInput1.LeftShoulder
keyboard.E = XInput1.RightShoulder

//360 Buttons ABXY
keyboard.G = XInput1.A
keyboard.tab = XInput1.B
keyboard.Y = XInput1.Y
keyboard.V = XInput1.X

//360 dPad
keyboard.4 = Xinput1.Up
keyboard.7 = Xinput1.Right
keyboard.5 = Xinput1.Down
keyboard.6 = Xinput1.Left

//360 Start and Select
keyboard.esc = XInput1.start
keyboard.space = XInput1.back

//360 Triggers
Mouse.LeftButton = XInput1.LeftTrigger
keyboard.R = XInput1.RightTrigger

//360 Stick Clicks
keyboard.B = XInput1.LeftThumb
keyboard.capslock = XInput1.RightThumb

as i said though im happy w/ how that looks so far and it runs correctly. i just havent tested its ease of use in the game. and would be very grateful if somebody whos familiar with the glovepie scripting could please help me with a command i can use to counter my ♥♥♥♥♥y analog...
Last edited by swift_wrath; Nov 19, 2013 @ 4:37am
< >
Showing 1-9 of 9 comments
swift_wrath Nov 19, 2013 @ 3:54am 
Originally posted by Fred:
This forum is great for controller expertise:
Big Picture
thanks but at this point my visions going a little blurry from hours upon hours of studying forums for both fixing the issues im having with kotor 1 and 2 as well as solutions for the analog issue. so navigating and then finding the relevant data is a bit out of my grasp. can you narrow it down with the term i need or a more specific place to find it?
Last edited by swift_wrath; Nov 19, 2013 @ 3:55am
swift_wrath Nov 19, 2013 @ 4:01am 
Originally posted by Fred:
Originally posted by swift_wrath:
thanks but at this point my visions going a little blurry from hours upon hours of studying forums for both fixing the issues im having with kotor 1 and 2 as well as solutions for the analog issue. so navigating and then finding the relevant data is a bit out of my grasp. can you narrow it down with the term i need or a more specific place to find it?

I was more suggesting for you to make your post in that forum.
oh, ok thanks =D lol
swift_wrath Nov 19, 2013 @ 4:03am 
i was having a pain in the ass of a time finding the most relevant forum and settled on this one to get it started =D
swift_wrath Nov 19, 2013 @ 4:06am 
Originally posted by Fred:
This forum is great for controller expertise:
Big Picture
is there a specific post you think i should start in or might it be better to start a new one as i did here. this is my 1st time actually posting as i usually find what im looking for or give up entirely opting to go in a different direction..
swift_wrath Nov 19, 2013 @ 4:07am 
Originally posted by Fred:
Be sure to link us to your new thread. When somebody else stumbles upon this thread to find help, they know where to find it.
k, np =D
swift_wrath Nov 19, 2013 @ 4:14am 
ive started it by copy/pasting the original post in a new post but cant get the post button to cooperate. as soon as i get it to though ill post a link over. i think its probably due to a nasty ramnit virus i have atm and havent had the time to wipe the comp completely clean to start anew
swift_wrath Nov 19, 2013 @ 4:18am 
Originally posted by Fred:
Be sure to link us to your new thread. When somebody else stumbles upon this thread to find help, they know where to find it.
http://steamcommunity.com/groups/bigpicture/discussions/1/666826251200862593/
swift_wrath Nov 19, 2013 @ 6:42am 
lol, way too much coffee, wayyyy to many hours of being up consecutively, and the fact that its been almost a year since i wrote any code and i find that i made the most ♥♥♥♥♥♥♥♥ mistake i probably could have.. lol
upon still having absolutely no luck finding what i was looking for in forums i went back to my script and started comparing it to some of my older scripts to find a solution.
after a while of looking right at it and not seeing it, it all came flooding back.
the number i was adjusting before is the one just before the deadzone command and does indeed of course pertain to sensitivity.
the equation immediately following the deadzone command pertains to the dead zone.
in other words deadzone IS the command for pressure required and thus is what i needed to adjust.
maybe its because the script above doesnt have a numerical value within the equation that it took me sooo long to realize it.

for example:

Mouse.DirectInputX = Mouse.DirectInputX + 10*deadzone(XInput1.Joy2X)

adjusting the above value of 10 will of course adjust the sensitivity of the mouse movement to slower w/ a lower value and faster w/ a higher value.

while adding a numerical value to the end of the equation pertaining to the deadzone will adjust the pressure required to activate the output.

ie: Mouse.DirectInputX = Mouse.DirectInputX + 10*deadzone(XInput1.Joy2X0.2)

im still running some trouble shooting to compensate for the pull of the analog but this solves the problem..

FUNNY HOW ONE CAN MAKE THEMSELVES FEEL LIKE A COMPLETE JACKASS SOMETIMES...

LM MUTHA ♥♥♥♥IN AO

and remember kids too much caffeine and sleep dep is bad mmk
Spawn of Totoro Nov 19, 2013 @ 6:45am 
http://glovepie.org/forum/

Best place to find help with your scripting issue.
< >
Showing 1-9 of 9 comments
Per page: 1530 50

Date Posted: Nov 19, 2013 @ 3:43am
Posts: 9