Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a console command
sar_sensitivity <cm/in> <distance> <dpi>that allows users to enter either a inches/360 or a centimeters/360 value along with their dpi to change their sens to the sens that makes that distance/360 value. Requested by issue #312, some users are more familiar with the distance/360 that they play at or would like to make adjustments using distance/360. This also helps users coming from other games that may not use the source sensitivity system.With
m_rawinput 1this feature trivially calculates the sensitivity required, and withm_rawinput 0(*on windows) will consider their windows sensitivity settings to create a sensitivity that will make the distance/360. While windows mouse acceleration defeats the purpose of a set distance/360, it is still considered in calculating the required sensitivity.Unfortunately operating system sensitivity settings cannot be easily obtained on Linux, so any usage of the command with
m_rawinput 0will have a chance of being inaccurate if mouse acceleration or sensitivity is changed in OS.This is being submitted as a draft for two reasons: first being that I do not have access to Portal 2 on Linux so I need someone to make sure that the windows only carve outs actually work, secondly there is still the need to consider if
m_customaccelsettings need to be considered when setting a distance/360. Currently my understanding is that it is not possible becausem_customaccelworks directly with the raw mouse movement delta, and no amount of changing the sensitivity is going to be able to make the mouse speed actually conform to your distance/360 (doinghelp m_customaccelin game shows the formulas used, which directly change the delta first then add the sensitivity), but I don't know for sure.On a final note I left my comments to help with my understanding but they can be removed.