Crzyrndm Posted November 4, 2014 Share Posted November 4, 2014 (edited) All my minor mods are going into a single thread post-1.0 release. Please check my signature for the new threadThis plugin brings a common flight sim feature to KSP. A way to use your mouse to control your vessel for those who don't use gamepads and/or joysticks.When activated, pitch and roll control inputs are the result of the position of the cursor onscreen. There's a deadzone along the center of each axis past which inputs scale towards the screen edges (reaching maximum 2/3rds of the way to the edge). Keyboard pitch/roll input is ignored while it's active.Control is much more intuitive with the camera set to chase mode Download Instructions for use:​Press the Enter/Return key to make the UI visible (control remains w/e you were using without this mod) Click the Left Mouse Button to activate mouse controlTab key allows switching between roll (default) and yaw control. This can be changed at any time and is persistent through a flight, but the only indication of the current mode is the control behaviour [*]Click again to pause mouse control (control output will remain as it was when you pause) [*]Press Enter/Return key to regain control through other flight inputs. Configuration file for x/y <range/deadzone/position>, and target transparency is generated upon leaving the flight scene. Changes made should be loaded upon re-entering flight (no need to restart).Distributed under CC BY-NC-SA 4.0 licensev1.5 * Added two stage activation when the setting centerlineVisible is true. * Added control pause (holds output state) * Added pause location indicationv 1.4 * Added settings for center location * Fixed center not being correctly accounted for * Center is now trimmedv 1.3 * Added settings for range and deadzonev1.2 * Added invert pitch axis option * Added optional HUD target to indicate location of deadzones. Transparency configurable * .version file * No longer a part module (why it ever was, I don't know)v1.1 * Control input scaling changed to quadratic relationship with displacement for better fine control * Changed activation key from numpad enter to standard enter/return key * Added yaw control mode, switch between roll and yaw control using the tab key Edited April 26, 2015 by Crzyrndm Link to comment Share on other sites More sharing options...
MonaBabii Posted November 4, 2014 Share Posted November 4, 2014 Does toggling "Fine control" with tabs lock help at all with that "extreme"ness? or does it apply the same strength (to put it some way)? I'm almost tempted to get this just because all of my planes always look like they are getting punched every time I try to turn or roll or whatever, the motion is so jerky and so wrong looking lol. This thing looks like the next best thing after a Joystick if you wanna get fluid motion. Link to comment Share on other sites More sharing options...
skykooler Posted November 4, 2014 Share Posted November 4, 2014 This looks awesome, I've been wanting this option for years! Two things though: one, would it be possible to make this activated by something not on the numpad? My laptop doesn't have one. And two: there should be a way to invert the y axis so it matches up with joysticks (and the mouse control option of other flight simulators). Link to comment Share on other sites More sharing options...
LitaAlto Posted November 4, 2014 Share Posted November 4, 2014 This could make flying a lot more fun and practical for me! Thanks! Link to comment Share on other sites More sharing options...
Crzyrndm Posted November 4, 2014 Author Share Posted November 4, 2014 Does toggling "Fine control" with tabs lock help at all with that "extreme"ness? or does it apply the same strength (to put it some way)? I'm almost tempted to get this just because all of my planes always look like they are getting punched every time I try to turn or roll or whatever, the motion is so jerky and so wrong looking lol. This thing looks like the next best thing after a Joystick if you wanna get fluid motion.As it stands, no it totally overrides the stock input functionality on the axes it controls. I have hardcoded sensitivity options for testing, but the need wasn't there for ingame adjustment (it is fairly high on the list of improvements...)This looks awesome, I've been wanting this option for years! Two things though: one, would it be possible to make this activated by something not on the numpad? My laptop doesn't have one. And two: there should be a way to invert the y axis so it matches up with joysticks (and the mouse control option of other flight simulators).Any suggestion for a better key choice? Numpad is nice because it doesn't get much use, but I forgot about laptops .RE: all the other stuffSensitivity, axis inversion, yaw/roll switching (for flying planes and rockets), X/Y RCS control. All are on the list for possible expanded control features. Link to comment Share on other sites More sharing options...
Crzyrndm Posted November 4, 2014 Author Share Posted November 4, 2014 (edited) Updated to v1.1 to fix a few of the more pressing problems.Control is significantly smoother through the use of a quadratic relationship to displacement.Activation key is now standard Enter/Return, not the numpad versionRoll control can also now be replaced by yaw control (left/right) using the tab keyIt is MUCH easier to fly with the finer level of control from the new scaling. Does it still need on the fly switching (aka stock fine control mode)? Edited November 4, 2014 by Crzyrndm Link to comment Share on other sites More sharing options...
LitaAlto Posted November 6, 2014 Share Posted November 6, 2014 Is there a compiled version of this? I only see source files. Link to comment Share on other sites More sharing options...
Crzyrndm Posted November 6, 2014 Author Share Posted November 6, 2014 (edited) Uh, did I derp?E:Oh, the github download is labelled as source (erps) but includes a gamedata folder with the .dll and MM patch. Edited November 6, 2014 by Crzyrndm Link to comment Share on other sites More sharing options...
Roman_Cohort Posted February 8, 2015 Share Posted February 8, 2015 Thanks for the mod. now Ma Landings look more professional Link to comment Share on other sites More sharing options...
Ser Posted February 19, 2015 Share Posted February 19, 2015 (edited) Very useful. The feel of flying a spaceplane is much better with this. Almost a must have if you do not have a hardware joy.Does it take any trimming into account?And one more thing I've noticed: if I set my controls to, say, a level flight at low speed and press "Enter" to exit control mode then my spaceplane noticeably ducks. Seems like it doesn't remember control angles and just sets everything to neutral when released. That annoys a bit if happens on final approach or other near-stall or low altitude flight situations.Some suggestions:Really lacks a vertically inversed mouse input as controlling in the present way is a bit unnatural.Would be useful to have a toggleable centerline display (with configurable transparency). But do not overdo with displayed things as I really love that your mod doesn't block the view by anything. Edited February 19, 2015 by Ser Link to comment Share on other sites More sharing options...
Crzyrndm Posted February 19, 2015 Author Share Posted February 19, 2015 Does it take any trimming into account?And one more thing I've noticed: if I set my controls to, say, a level flight at low speed and press "Enter" to exit control mode then my spaceplane noticeably ducks. Seems like it doesn't remember control angles and just sets everything to neutral when released. That annoys a bit if happens on final approach or other near-stall or low altitude flight situations.Some suggestions:Really lacks a vertically inversed mouse input as controlling in the present way is a bit unnatural.Would be useful to have a toggleable centerline display (with configurable transparency). But do not overdo with displayed things as I really love that your mod doesn't block the view by anything.Trimming not acounted for I believe, and yes when it disengages everything goes back to neutral.RE: SuggestionsI really should do some work on this. Originally it was a spinoff of some prep work I was doing for Pilot Assistant and it hasn't had all that much attention since.I agree entirely with your suggestions, it's just a matter of finding some time to do some work on this Link to comment Share on other sites More sharing options...
Crzyrndm Posted February 20, 2015 Author Share Posted February 20, 2015 (edited) Analog Control v1.2Added invert pitch axis optionAdded optional HUD target to indicate location of deadzones. Transparency configurable.version fileNo longer a part module (why it ever was, I don't know)Settings can be found in the pluginData folder after you exit the flight scene once. Transparency is <0-1>, other options are boolean 0 or 1 Edited February 20, 2015 by Crzyrndm Link to comment Share on other sites More sharing options...
Ser Posted February 20, 2015 Share Posted February 20, 2015 Nice! But where have deadzone settings gone? Also it would be nice to have some non-linearity tweak because of lack of power at the edges: pressing a key has more effect than having mouse at the edge of the screen.At my taste I'd made deadzones 2 times smaller and a steep sensitivity growth at the last quarter or fifth up to factor of 1:1 at the edge. At least in pitch because it's important to have full range of deviations there. Anyway it's individual. So separate non-linearity settings for pitch/roll/yaw would be just great. Link to comment Share on other sites More sharing options...
Crzyrndm Posted February 21, 2015 Author Share Posted February 21, 2015 (edited) But where have deadzone settings gone? Oops.v1.3Added deadzone and range settingsIf you're not getting 100% action at the screen edge with default settings (as of 1.3), something is wrong. It should reach max output 2/3rds of the way to an edge.Range setting is a percentage of screen width/height, deadzone is a % of range. The center texture will resize with alterations in range and deadzone to continue indicating the deadzone border.If you want to make a different center indication it needs a 500x500 px image and the deadzone is the center 200 pixels of each axis. I'm not averse to suggestions on how the texture can be improved Edited February 21, 2015 by Crzyrndm Link to comment Share on other sites More sharing options...
Ser Posted February 21, 2015 Share Posted February 21, 2015 "Groung control to Major Tom, your circuits dead, there's something wrong" Now for some reason the lower-left corner is considered as a center. And crosshairs are gone. Reverted to v1.2.If you want to make a different center indication it needs a 500x500 px image and the deadzone is the center 200 pixels of each axis. I'm not averse to suggestions on how the texture can be improvedI think that's ok. Anyway I can draw anything I like myself Link to comment Share on other sites More sharing options...
drtedastro Posted February 21, 2015 Share Posted February 21, 2015 Ok, I am confused.. download showing 1.2 to be the 'newest', yet 1.3 is shown below it.???Am i missing something, or just not enough coffee yet...cheers.. Link to comment Share on other sites More sharing options...
Crzyrndm Posted February 21, 2015 Author Share Posted February 21, 2015 "Groung control to Major Tom, your circuits dead, there's something wrong" Now for some reason the lower-left corner is considered as a center. And crosshairs are gone. Reverted to v1.2.Er, what on earth did I do...- - - Updated - - -*Smacks self in head*v1.4Correctly initialised center location once moreAdded center location to settingsCenter now depends on trim Link to comment Share on other sites More sharing options...
Ser Posted February 22, 2015 Share Posted February 22, 2015 Awesome. Now using this with FAR and AJE makes flying in KSP like a flight simulator.One more good feature might be if on pressing "Enter" a mouse was placed according the current control angles, so the vessel didn't start moving. Because if trying to control a rocket during launch you hardly know where the center will be and you have nearly 100% chance to break your trajectory just by switching.Not critical but for some reason if you try to control a rover it still lacks range: pressing a key makes it turn about twice faster. Tried 0.1, 1, 2 for rangeX.Why the settings for center are in absolute coordinates? It would be logical to specify them as offsets relative to the actual screen center.Should actual deadzones really depend on range settings like they do now? Link to comment Share on other sites More sharing options...
Crzyrndm Posted February 22, 2015 Author Share Posted February 22, 2015 (edited) One more good feature might be if on pressing "Enter" a mouse was placed according the current control angles, so the vessel didn't start moving. Because if trying to control a rocket during launch you hardly know where the center will be and you have nearly 100% chance to break your trajectory just by switching.How about a delay where the GUI shows up but the mouse is not yet used for control (or maybe enter once: GUI, twice: control, third time: off with a timeout of 5-10s on the first-> second stage transition)Not critical but for some reason if you try to control a rover it still lacks range: pressing a key makes it turn about twice faster. Tried 0.1, 1, 2 for rangeX.Why the settings for center are in absolute coordinates? It would be logical to specify them as offsets relative to the actual screen center.Should actual deadzones really depend on range settings like they do now?Rover: are the wheels turning at all? That sort of sounds like all turning is being done by reaction wheels or something of the sort. I'll have a poke aroundSettings: Numbers are just plucked out as they are from the code. I can certainly reformat them if there is a consensus as to what is appropriate. Deadzone I'm not particularly concerned about, but I much prefer absolute coordinates (because as you mention previously, the center of the screen isn't exactly marked), although maybe a percentage of screen width/height would work better. Edited February 22, 2015 by Crzyrndm Link to comment Share on other sites More sharing options...
Ser Posted February 22, 2015 Share Posted February 22, 2015 (edited) I'll check that with reaction wheels off.And one more idea that could be useful as I think: when the control mode is going to off set trimming to current position so a vessel remembers where the control surfaces were, keep going in present direction and doesn't duck. With this on exit and setting mouse on enter (as I wrote earlier) that enter/exit disturbance of a craft would be eliminated.The difficulty may be in what to do with previously set trimming when entering control mode. It could be just dropped to default because the mouse position sets trimming in case it works as I've proposed. Edited February 22, 2015 by Ser Link to comment Share on other sites More sharing options...
life_on_venus Posted February 22, 2015 Share Posted February 22, 2015 So... War Thunder "simple" controls in KSP? Fantastic! Link to comment Share on other sites More sharing options...
Crzyrndm Posted February 22, 2015 Author Share Posted February 22, 2015 (edited) So... War Thunder "simple" controls in KSP? Fantastic!Or MS Flight Simulator's mouse yoke, or w/e X-Plane/Prepar3d calls it. Mouse control systems are fairly common in Flight Sim'sOn another note, it just occured to me that the settings file is probably (I can't test right now...) being read from disc every time you enter the flight scene. If you want to play around with the config, you should be able to just jump out to the space center, make your changes, and them jump back into flying/driving a plane/rocket/rover.RE: Improving activationHow about enter "arm"s the system (giving you the GUI), while a mouse click unpauses/pauses control (with paused control holding the current input, probably drawing a red dot or something to indicate where that is) Edited February 22, 2015 by Crzyrndm Link to comment Share on other sites More sharing options...
Enceos Posted February 24, 2015 Share Posted February 24, 2015 Thank you Crzyrndm! You made the best two mods for planes controlling out there. I can't express how grateful I am )These mods changed my flying completely. Link to comment Share on other sites More sharing options...
Crzyrndm Posted February 24, 2015 Author Share Posted February 24, 2015 (edited) @enceosAlways nice to hear people appreciates my efforts On another note:If you're looking for something more advanced/configurable, this looks to have it well and truly covered (or will after the dev updates to include a few suggestions I made based on Analog Control). Edited February 24, 2015 by Crzyrndm Link to comment Share on other sites More sharing options...
Crzyrndm Posted March 1, 2015 Author Share Posted March 1, 2015 (edited) Version 1.5Added a two stage activation when using the GUI. The first stage makes the crosshair visible, and then you can pause and unpause control (always paused when you make the crosshair visible)Enter/Return is now the on/off switch (show/hide the crosshair). Left Mouse Button is pause/unpause (not available if the UI setting is false, activation remains as it was with that)After transferring from an unpaused to a paused state (normal input still functions after you show the crosshair until you unpause control), the mouse position is remembered and continues to be used for outputs.A small dot is placed at the cursor location when control is paused so you can re-engage smoothlyThe marker texture is a 20x20 PNG, with the last cursor position being centered at (10,10). If you want it gone just replace it with a fully transparent PNG of the same size (or edit it to your preference ofcourse)If you want the pause/hold functionality without the crosshair you can always set the transparency to full.OP usage instructions updated to reflect changesInstructions for use:​Press the Enter/Return key to make the UI visible (control remains w/e you were using without this mod)Click the Left Mouse Button to activate mouse controlTab key allows switching between roll (default) and yaw control. This can be changed at any time and is persistent through a flight, but the only indication of the current mode is the control behaviour [*]Click again to pause mouse control (control output will remain as it was when you pause)[*]Press Enter/Return key to regain control through other flight inputs.And a new video NOTE:The pause function is only remembering where you had your mouse when it was activated. Changing the trim and switching between yaw/roll control will change the outputs Edited March 1, 2015 by Crzyrndm Link to comment Share on other sites More sharing options...
Recommended Posts