Add support for Tiberian Sun style right-click-and-drag scrolling
This patch introduces support for the right-click-and-drag scrolling that is available in Tiberian Sun and Red Alert 2. It can be enabled by selecting "Joystick" scrolling in the Input settings. The speed of the scroll is proportional to the product of the distance of the drag, and the Scroll Speed selected in the Input settings menu. A side-effect of this is that events previously tied to right clicks on the world are now based on the release of the click rather than the press. The "Middle-Mouse Scrolling:" option is renamed to "Mouse Scrolling Method:"
This commit is contained in:
@@ -19,7 +19,7 @@ using OpenRA.Traits;
|
||||
|
||||
namespace OpenRA
|
||||
{
|
||||
public enum MouseScrollType { Disabled, Standard, Inverted }
|
||||
public enum MouseScrollType { Disabled, Standard, Inverted, Joystick }
|
||||
|
||||
public class ServerSettings
|
||||
{
|
||||
@@ -167,6 +167,7 @@ namespace OpenRA
|
||||
public float ViewportEdgeScrollStep = 10f;
|
||||
public float UIScrollSpeed = 50f;
|
||||
public int SelectionDeadzone = 24;
|
||||
public int JoystickScrollDeadzone = 8;
|
||||
|
||||
public bool UseClassicMouseStyle = false;
|
||||
public bool AlwaysShowStatusBars = false;
|
||||
|
||||
Reference in New Issue
Block a user