#1 2017-09-23 09:33:42

iCQ
Player
Saint Martin
Reputation: 31
Registered: 2017-07-31
Posts: 233
Linux Vivaldi 1.92

Gaming on linux tips

The other day i had to switch mouse due to an empty mouse and the laziness for getting new batteries. But since i am a linux gamer i ran into a little problem! This USB gaming mouse had a crazy DPI of 4000 so my mouse pointer went crazy over my desktop and the mouse speed settings in my ubuntu distro just wouldnt fix it for me. So i googled:

https://patrickmn.com/aside/lowering-ga … untu-9-10/

In essence on the terminal i typed:

xinput --list --short

to get a list of my input devices:

icq@icq-b0x:~$ xinput --list --short
⎡ Virtual core pointer                    	id=2	[master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer              	id=4	[slave  pointer  (2)]
⎜   ↳ Telink Wireless Receiver                	id=10	[slave  pointer  (2)]
⎜   ↳ Logitech USB Receiver                   	id=11	[slave  pointer  (2)]
⎜   ↳ Logitech USB Receiver                   	id=12	[slave  pointer  (2)]
⎜   ↳ E-Signal USB Gaming Mouse               	id=13	[slave  pointer  (2)]
⎜   ↳ E-Signal USB Gaming Mouse               	id=14	[slave  pointer  (2)]
⎜   ↳ PS/2 Generic Mouse                      	id=17	[slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad              	id=18	[slave  pointer  (2)]
⎣ Virtual core keyboard                   	id=3	[master keyboard (2)]
    ↳ Virtual core XTEST keyboard             	id=5	[slave  keyboard (3)]
    ↳ Power Button                            	id=6	[slave  keyboard (3)]
    ↳ Video Bus                               	id=7	[slave  keyboard (3)]
    ↳ Sleep Button                            	id=8	[slave  keyboard (3)]
    ↳ Telink Wireless Receiver                	id=9	[slave  keyboard (3)]
    ↳ HP HD Webcam [Fixed]                    	id=15	[slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard            	id=16	[slave  keyboard (3)]
    ↳ HP WMI hotkeys                          	id=19	[slave  keyboard (3)]
    ↳ Telink Wireless Receiver                	id=20	[slave  keyboard (3)]
    ↳ Logitech USB Receiver                   	id=21	[slave  keyboard (3)]
    ↳ E-Signal USB Gaming Mouse               	id=22	[slave  keyboard (3)]

Under VIRTUAL CORE POINTER i find two entries for my gaming mouse, id 13 and 14. Lets list the properties of both to see which one actually has the acceleration value in it.

icq@icq-b0x:~$ xinput --list-props 13
Device 'E-Signal USB Gaming Mouse':
	Device Enabled (153):	1
	Coordinate Transformation Matrix (155):	1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
	libinput Accel Speed (289):	-1.000000
	libinput Accel Speed Default (290):	0.000000
	libinput Accel Profiles Available (291):	1, 1
	libinput Accel Profile Enabled (292):	1, 0
	libinput Accel Profile Enabled Default (293):	1, 0
	libinput Natural Scrolling Enabled (294):	0
	libinput Natural Scrolling Enabled Default (295):	0
	libinput Send Events Modes Available (274):	1, 0
	libinput Send Events Mode Enabled (275):	0, 0
	libinput Send Events Mode Enabled Default (276):	0, 0
	libinput Left Handed Enabled (296):	0
	libinput Left Handed Enabled Default (297):	0
	libinput Scroll Methods Available (298):	0, 0, 1
	libinput Scroll Method Enabled (299):	0, 0, 0
	libinput Scroll Method Enabled Default (300):	0, 0, 0
	libinput Button Scrolling Button (301):	2
	libinput Button Scrolling Button Default (302):	2
	libinput Middle Emulation Enabled (303):	0
	libinput Middle Emulation Enabled Default (304):	0
	Device Node (277):	"/dev/input/event7"
	Device Product ID (278):	1241, 41119
	libinput Drag Lock Buttons (305):	<no items>
	libinput Horizontal Scroll Enabled (306):

and ID 14 gave me this:

xinput --list-props 14
Device 'E-Signal USB Gaming Mouse':
	Device Enabled (153):	1
	Coordinate Transformation Matrix (155):	1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
	libinput Natural Scrolling Enabled (294):	0
	libinput Natural Scrolling Enabled Default (295):	0
	libinput Send Events Modes Available (274):	1, 0
	libinput Send Events Mode Enabled (275):	0, 0
	libinput Send Events Mode Enabled Default (276):	0, 0
	Device Node (277):	"/dev/input/event8"
	Device Product ID (278):	1241, 41119
	libinput Drag Lock Buttons (305):	<no items>
	libinput Horizontal Scroll Enabled (306):	1

Obviously the second one (id=14) does not have any acceleration properties. The reason why this mouse has two (actually three) USB entries is because this gaming mouse has 9 extra keys on it for macro's, colored leds and other funny stuff. All we are interested in is the acceleration of the mouse pointer found under id=13 libinput Accel Speed which was set to value 1. Since i want to lower the speed i set it on the lowest value possible which is -1. I tried -0.5 but that was still too high:

How to set it with the xinput command:

 xinput --set-prop 13 "libinput Accel Speed" -1 

So that is the terminal command to adjust the pointer speed to my liking.

To make this setting run on every boot i created a mouse-fix.sh file using nano.
(one of my favorite text editors, u can use ur own obviously)

After that a chmod -x mouse-fix.sh in the terminal to make the file executable. Then i added mouse-fix.sh to my Startup Applications.

Since i was already there i also added in a command to enlarge my mouse cursor... just for the fun of it (larger than the mouse settings allows).
[code=mouse-fx.sh]#set mouse cursor size
gsettings set org.gnome.desktop.interface cursor-size 64
#set mouse pointer speed
xinput --set-prop 13 "libinput Accel Speed" -1 [/code]

Also i installed a few windows games in linux yesterday (overwatch from blizzard is for free this weekend!) and i had some screen resolution issues. Sometimes some windows games running in WINE mess up the screen resolution. So i decided to add a little keyboard shortcut that will reset my screen to default (max) resolution:

Start menu/panel->System Settings..->Keyboard->Shortcuts

There i went to CUSTOM SHORTCUTS and i clicked the + symbol to create a new keyboard shortcut. To reset my screen i used this command:
[code]xrandr --output VGA-0 --mode 1920x1200[/code]
and i linked it with the CTRL-ALT-R keyboard shortcut.

How about you? Any linux gaming tips?

mouse.png

Last edited by iCQ (2017-09-23 09:41:44)


Admin mouth gagged me without a word, the saddist non man. I warn you!

Offline

    0   Add Reputation to this user  Remove Reputation from this user

#2 2017-09-23 11:11:02

petr8
Ulyachka
Reputation: 43
Registered: 2016-10-13
Posts: 115
Linux Firefox 55.0

Re: Gaming on linux tips

iCQ wrote:

To make this setting run on every boot i created a mouse-fix.sh file using nano.

Wouldn't be easier to add this to cron?

Sometimes some windows games running in WINE mess up the screen resolution.

Rarely i see the same bug and use a similar to your solution.

How about you? Any linux gaming tips?

Below is a piece of my .desktop file that I put to /usr/share/applications/ to launch the game directly from the Dock:

bf1942.desktop
[Desktop Entry]
Name=Battlefield 1942
Exec=wine BF1942.exe +game BF1942  +restart 1	
Path=/opt/bf1942/
Icon=/opt/bf1942/icon.ico
Terminal=false
Type=Application
Categories=Games;Wine;
Actions=Simple;

[Desktop Action Simple]
Name=Simple FRA
Exec=wine BF1942.exe +game BF1942  +restart 1 +joinServer 188.165.220.115:14567 +isInternet 1 +reconnectPassword +NoDll 1

To skip entering the password on a protected servers add "+password <pass>" key to the Exec line.

Offline

    +1   Add Reputation to this user  Remove Reputation from this user

#3 2017-09-23 22:33:16

amd
Player
Estonia
Reputation: 4
Registered: 2017-07-30
Posts: 13
Windows 10 Chrome 61.0

Re: Gaming on linux tips

petr8 wrote:
Exec=wine BF1942.exe +game BF1942  +restart 1 +joinServer 188.165.220.115:14567 +isInternet 1 +reconnectPassword +NoDll 1

What does NoDll do?

Offline

    +1   Add Reputation to this user  Remove Reputation from this user

#4 2017-09-23 22:39:24

Arkos
Member
Switzerland
Reputation: 501
Registered: 2014-06-06
Posts: 2,205
Windows 7 Chrome 60.0

Re: Gaming on linux tips

...

Some Hax disabled... big_smile

But i guess it's disabling CD-Check

...

Offline

    +1   Add Reputation to this user  Remove Reputation from this user

#5 2017-09-24 22:55:36

iCQ
Player
Saint Martin
Reputation: 31
Registered: 2017-07-31
Posts: 233
Ubuntu Chromium 61.0

Re: Gaming on linux tips

petr8 wrote:

Wouldn't be easier to add this to cron?

Yes, no... i do not want this to run in a timely fasion, just once after boot. Good tip tho!


petr8 wrote:

Sometimes some windows games running in WINE mess up the screen resolution.

Rarely i see the same bug and use a similar to your solution.

Some games i want to run in lower resolution and since i have a multi monitor setup... wink

petr8 wrote:

Below is a piece of my .desktop file that I put to /usr/share/applications/ to launch the game directly from the Dock:

bf1942.desktop
[Desktop Entry]
Name=Battlefield 1942
Exec=wine BF1942.exe +game BF1942  +restart 1	
Path=/opt/bf1942/
Icon=/opt/bf1942/icon.ico
Terminal=false
Type=Application
Categories=Games;Wine;
Actions=Simple;

[Desktop Action Simple]
Name=Simple FRA
Exec=wine BF1942.exe +game BF1942  +restart 1 +joinServer 188.165.220.115:14567 +isInternet 1 +reconnectPassword +NoDll 1

To skip entering the password on a protected servers add "+password <pass>" key to the Exec line.

Nice tip! I use a similar launch except for the NoDll 1 part. Not sure anymore what that one is about (no DLL file loading???). Also i have no icons on my desktop... i use xfce panels.


Admin mouth gagged me without a word, the saddist non man. I warn you!

Offline

    0   Add Reputation to this user  Remove Reputation from this user

#6 2017-09-24 22:57:03

iCQ
Player
Saint Martin
Reputation: 31
Registered: 2017-07-31
Posts: 233
Ubuntu Chromium 61.0

Re: Gaming on linux tips

@petr8

wine '/mnt/500GB/Games/Battlefield 1942/BF1942.exe' +restart 1  +joinServer 94.23.196.155:14567 +game bf1942 +playerName linux

is my shortcut to the game.


Admin mouth gagged me without a word, the saddist non man. I warn you!

Offline

    +1   Add Reputation to this user  Remove Reputation from this user

#7 2017-09-25 02:11:19

iCQ
Player
Saint Martin
Reputation: 31
Registered: 2017-07-31
Posts: 233
Linux Vivaldi 1.92

Re: Gaming on linux tips

I have to thank petr8 for somehow reminding me to check my cron folders. Gosh what a mess i have in there, all sorts of daemons and clutter working in the background i should have cleaned up a few months ago when i came back over the border to the Netherlands.

Another reason i choose not to use cron for these mouse settings is that often i run this box without any X window server/manager. And in those cases i dont want these mouse pointer settings to load.


Admin mouth gagged me without a word, the saddist non man. I warn you!

Offline

    0   Add Reputation to this user  Remove Reputation from this user

#8 2017-09-27 13:37:50

iCQ
Player
Saint Martin
Reputation: 31
Registered: 2017-07-31
Posts: 233
Unknown Firefox 55.0

Re: Gaming on linux tips

A very good article about playing on linux (2017) is here:
http://howtouselinux.net/best-linux-distro-for-gaming/

From this article the biggest tip for u here would be, i guess, the tool PlayOnLinux.

The rest of the distros named here most of u probably already know or are actually using at the moment.

Not sure if bf1942 will be easely made to run on SteamOS so beware of that.

Is anyone of u using CrossOver software instead of wine for Battlefield 1942? Is it run better than wine.for.u?

Anyways i guess thats it for today, take care &have fun!


Admin mouth gagged me without a word, the saddist non man. I warn you!

Offline

    +1   Add Reputation to this user  Remove Reputation from this user

Board footer