Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
openmw
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
466
Issues
466
List
Boards
Labels
Service Desk
Milestones
Merge Requests
12
Merge Requests
12
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenMW
openmw
Commits
d791dcfb
Commit
d791dcfb
authored
Dec 06, 2018
by
Marc Zinnschlag
1
Browse files
Options
Browse Files
Download
Plain Diff
Merged pull request
#2051
parents
5700394c
7b5932a4
Pipeline
#39185871
passed with stage
Changes
6
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
39 additions
and
6 deletions
+39
-6
CHANGELOG.md
CHANGELOG.md
+1
-0
inputmanagerimp.cpp
apps/openmw/mwinput/inputmanagerimp.cpp
+6
-2
inputmanagerimp.hpp
apps/openmw/mwinput/inputmanagerimp.hpp
+1
-0
input.rst
docs/source/reference/modding/settings/input.rst
+14
-0
openmw_settings_window.layout
files/mygui/openmw_settings_window.layout
+14
-4
settings-default.cfg
files/settings-default.cfg
+3
-0
No files found.
CHANGELOG.md
View file @
d791dcfb
...
...
@@ -12,6 +12,7 @@
Bug #4746: Non-solid player can't run or sneak
Feature #2229: Improve pathfinding AI
Feature #3442: Default values for fallbacks from ini file
Feature #3610: Option to invert X axis
Feature #4673: Weapon sheathing
Task #4686: Upgrade media decoder to a more current FFmpeg API
...
...
apps/openmw/mwinput/inputmanagerimp.cpp
View file @
d791dcfb
...
...
@@ -52,6 +52,7 @@ namespace MWInput
,
mUserFile
(
userFile
)
,
mDragDrop
(
false
)
,
mGrabCursor
(
Settings
::
Manager
::
getBool
(
"grab cursor"
,
"Input"
))
,
mInvertX
(
Settings
::
Manager
::
getBool
(
"invert x axis"
,
"Input"
))
,
mInvertY
(
Settings
::
Manager
::
getBool
(
"invert y axis"
,
"Input"
))
,
mControlsDisabled
(
false
)
,
mCameraSensitivity
(
Settings
::
Manager
::
getFloat
(
"camera sensitivity"
,
"Input"
))
...
...
@@ -467,7 +468,7 @@ namespace MWInput
float
rot
[
3
];
rot
[
0
]
=
yAxis
*
(
dt
*
100.0
f
)
*
10.0
f
*
mCameraSensitivity
*
(
1.0
f
/
256.
f
)
*
(
mInvertY
?
-
1
:
1
)
*
mCameraYMultiplier
;
rot
[
1
]
=
0.0
f
;
rot
[
2
]
=
xAxis
*
(
dt
*
100.0
f
)
*
10.0
f
*
mCameraSensitivity
*
(
1.0
f
/
256.
f
);
rot
[
2
]
=
xAxis
*
(
dt
*
100.0
f
)
*
10.0
f
*
mCameraSensitivity
*
(
1.0
f
/
256.
f
)
*
(
mInvertX
?
-
1
:
1
)
;
// Only actually turn player when we're not in vanity mode
if
(
!
MWBase
::
Environment
::
get
().
getWorld
()
->
vanityRotateCamera
(
rot
))
...
...
@@ -646,6 +647,9 @@ namespace MWInput
for
(
Settings
::
CategorySettingVector
::
const_iterator
it
=
changed
.
begin
();
it
!=
changed
.
end
();
++
it
)
{
if
(
it
->
first
==
"Input"
&&
it
->
second
==
"invert x axis"
)
mInvertX
=
Settings
::
Manager
::
getBool
(
"invert x axis"
,
"Input"
);
if
(
it
->
first
==
"Input"
&&
it
->
second
==
"invert y axis"
)
mInvertY
=
Settings
::
Manager
::
getBool
(
"invert y axis"
,
"Input"
);
...
...
@@ -827,7 +831,7 @@ namespace MWInput
{
resetIdleTime
();
float
x
=
arg
.
xrel
*
mCameraSensitivity
*
(
1.0
f
/
256.
f
);
float
x
=
arg
.
xrel
*
mCameraSensitivity
*
(
1.0
f
/
256.
f
)
*
(
mInvertX
?
-
1
:
1
)
;
float
y
=
arg
.
yrel
*
mCameraSensitivity
*
(
1.0
f
/
256.
f
)
*
(
mInvertY
?
-
1
:
1
)
*
mCameraYMultiplier
;
float
rot
[
3
];
...
...
apps/openmw/mwinput/inputmanagerimp.hpp
View file @
d791dcfb
...
...
@@ -175,6 +175,7 @@ namespace MWInput
bool
mGrabCursor
;
bool
mInvertX
;
bool
mInvertY
;
bool
mControlsDisabled
;
...
...
docs/source/reference/modding/settings/input.rst
View file @
d791dcfb
...
...
@@ -94,6 +94,20 @@ meaning that it should remain set at 1.0 unless the player desires to have diffe
This setting can only be configured by editing the settings configuration file.
invert x axis
-------------
:Type: boolean
:Range: True/False
:Default: False
Invert the horizontal axis while not in GUI mode.
If this setting is true, moving the mouse to the left will cause the view to rotate counter-clockwise,
while moving it to the right will cause the view to rotate clockwise. This setting does not affect cursor movement in GUI mode.
This setting can be toggled in game with the Invert X Axis button in the Controls panel of the Options menu.
invert y axis
-------------
...
...
files/mygui/openmw_settings_window.layout
View file @
d791dcfb
...
...
@@ -214,6 +214,16 @@
<Property
key=
"Caption"
value=
"#{sControlsMenu1}"
/>
</Widget>
<Widget
type=
"HBox"
skin=
""
position=
"4 224 300 24"
align=
"Left Bottom"
>
<Widget
type=
"AutoSizedButton"
skin=
"MW_Button"
position=
"0 0 24 24"
align=
"Left Bottom"
>
<UserString
key=
"SettingCategory"
value=
"Input"
/>
<UserString
key=
"SettingName"
value=
"invert x axis"
/>
<UserString
key=
"SettingType"
value=
"CheckButton"
/>
</Widget>
<Widget
type=
"AutoSizedTextBox"
skin=
"SandText"
position=
"28 4 78 16"
align=
"Left Bottom"
>
<Property
key=
"Caption"
value=
"Invert X Axis"
/>
</Widget>
</Widget>
<Widget
type=
"HBox"
skin=
""
position=
"4 254 300 24"
align=
"Left Bottom"
>
<Widget
type=
"AutoSizedButton"
skin=
"MW_Button"
position=
"0 0 24 24"
align=
"Left Bottom"
>
<UserString
key=
"SettingCategory"
value=
"Input"
/>
<UserString
key=
"SettingName"
value=
"invert y axis"
/>
...
...
@@ -223,10 +233,10 @@
<Property
key=
"Caption"
value=
"#{sMouseFlip}"
/>
</Widget>
</Widget>
<Widget
type=
"TextBox"
skin=
"NormalText"
position=
"4 2
5
4 336 18"
align=
"Left Bottom"
>
<Widget
type=
"TextBox"
skin=
"NormalText"
position=
"4 2
8
4 336 18"
align=
"Left Bottom"
>
<Property
key=
"Caption"
value=
"Camera Sensitivity"
/>
</Widget>
<Widget
type=
"MWScrollBar"
skin=
"MW_HScroll"
position=
"4
27
8 336 18"
align=
"HStretch Bottom"
>
<Widget
type=
"MWScrollBar"
skin=
"MW_HScroll"
position=
"4
30
8 336 18"
align=
"HStretch Bottom"
>
<Property
key=
"Range"
value=
"10000"
/>
<Property
key=
"Page"
value=
"300"
/>
<UserString
key=
"SettingType"
value=
"Slider"
/>
...
...
@@ -236,11 +246,11 @@
<UserString
key=
"SettingMin"
value=
"0.2"
/>
<UserString
key=
"SettingMax"
value=
"5.0"
/>
</Widget>
<Widget
type=
"TextBox"
skin=
"SandText"
position=
"4 3
0
2 336 18"
align=
"Left Bottom"
>
<Widget
type=
"TextBox"
skin=
"SandText"
position=
"4 3
3
2 336 18"
align=
"Left Bottom"
>
<Property
key=
"Caption"
value=
"#{sLow}"
/>
<Property
key=
"TextAlign"
value=
"Left"
/>
</Widget>
<Widget
type=
"TextBox"
skin=
"SandText"
position=
"4 3
0
2 336 18"
align=
"Right Bottom"
>
<Widget
type=
"TextBox"
skin=
"SandText"
position=
"4 3
3
2 336 18"
align=
"Right Bottom"
>
<Property
key=
"Caption"
value=
"#{sHigh}"
/>
<Property
key=
"TextAlign"
value=
"Right"
/>
</Widget>
...
...
files/settings-default.cfg
View file @
d791dcfb
...
...
@@ -333,6 +333,9 @@ camera sensitivity = 1.0
# (>0.0, Because it's a multiplier values should be near 1.0)
camera y multiplier = 1.0
# Invert the horizontal axis while not in GUI mode.
invert x axis = false
# Invert the vertical axis while not in GUI mode.
invert y axis = false
...
...
MOB2
@MOB2
mentioned in issue
#4755 (closed)
·
Dec 17, 2018
mentioned in issue
#4755 (closed)
mentioned in issue #4755
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment