VOGONS


First post, by lincruste

User metadata
Rank Newbie
Rank
Newbie

Good morning,
First of all please forgive my bad english, I'll try to make it simple and bearable.
I'm using DosBox 0.74 to run LucasArts X-Wing, and in order to control the ship with the mouse, I have to change the default mouse sensitivity parameter.
Here is my question:
Is it possible to change this parameter on the fly without having to restart DosBox to make the change take effect ?

I've tried to create a batch file like this:

rem the batch sets a high sensitivity value:
config -set "sensitivity 900"
rem the batch launches x-wing:
call xwing.exe
rem the batch resets the mouse sensitivity to its default value:
config -set "sensitivity 100"

But it doesn't work like I'd want it to. The sensitivity value does change when I check it with the command line, but it does NOT change in the game.
Of course I can make a specific .conf file for X-Wing, but the idea was to stay in the same DosBox session after playing in order to use the mouse with the default value in Norton Commander or Deluxe Paint II without having to restart.
Does someone here have the same problem or an idea to make this work (if it's possible)?
Thank you and best regards.

Reply 1 of 8, by bloodbat

User metadata
Rank Oldbie
Rank
Oldbie

An .exe is NOT a batch so no need to "call" it, just execute it.
What you're trying to do only works with SVN builds, as far as I recall, and the format for the parameter is

config -set "sdl sensitivity=900"

Reply 2 of 8, by robertmo

User metadata
Rank l33t++
Rank
l33t++

what's the problem with restarting dosbox?

Reply 3 of 8, by lincruste

User metadata
Rank Newbie
Rank
Newbie

@bloodbat
Thank you very much for your answer!
I've downloaded the EmuCR-Dosbox-r3829 binary, removed the "call" instruction and tried your command, but it still doesn't work, the sensitivity of the mouse remains unchanged in X-Wing.

The resulting batch is:

config -set "sdl sensitivity=900"
sensitivity>resultat.txt
xwing.exe
config -set "sdl sensitivity=100"
sensitivity>>resultat.txt

And the text file "resultat.txt" gives these values, which confirms the sensitivity does change, however it has no effect in game:

900
100

Maybe I did not choose the correct SVN Build, do you have a piece of advice to pick the correct one ?
Thank you again for your help.

@robertmo
There is of course no matter at all with DosBox 0.74, I do not imply that it's not good or anything of this kind. I'm trying to change the mouse sensitivity value on the fly because I use to launch Norton Commander in the autoexec and it requires the default value of 100. This is a pure "quest for personnal comfort", a solution is not mandatory at all !
edit: once again I am sorry for my english !

Reply 4 of 8, by VileR

User metadata
Rank l33t
Rank
l33t

If a config setting is changeable at runtime it's enough to type it as a command followed by a parameter. (e.g. "sensitivity 100" at the prompt)

Though you've already confirmed that DOSBox registers your change, so if the mouse is not affected in-game, it might be an issue with SDL...
It seems you're using Windows - try opening a command prompt window, then type "set SDL_VIDEODRIVER=WINDIB", and launch DOSBox from the command line. See if you notice any changes.

[ WEB ] - [ BLOG ] - [ TUBE ] - [ CODE ]

Reply 5 of 8, by lincruste

User metadata
Rank Newbie
Rank
Newbie
VileRancour wrote:

try opening a command prompt window, then type "set SDL_VIDEODRIVER=WINDIB", and launch DOSBox from the command line. See if you notice any changes.

Hi, thank you for your answer !
I just tried it and it is the same thing, the sensitivity is modified when I call its value or redirect it in a text file, but it has still no effect in game.
What is puzzling me is the fact that setting the 900 value in my dosbox.conf file does work (of course the cursor gets far too fast in Norton Commander or other games in the current DosBox session).
I'm quite ignorant of the inner mechanisms of DosBox and Windows, do you think using a GNU/Linux DosBox build might solve my problem ?

Reply 6 of 8, by bloodbat

User metadata
Rank Oldbie
Rank
Oldbie

Funny...I just tried changing it on the fly and it didn't work for me either.
Perhaps, being an SDL property and all...it can't be changed on the fly?
The same thing will result if trying to change the output on the fly (no change).
With a decent .conf file or front-end, you'd be set...no need to launch Norton Commander, it creates an unnecesary problem with what seems like an impractical solution. Or you could learn the Norton Commander hotkeys 😜

Reply 7 of 8, by VileR

User metadata
Rank l33t
Rank
l33t

Hmm. Yes, looking at the code, both "sensitivity" and "output" are changeable on the fly as far as DOSBox is concerned, but SDL probably knows nothing of that, so whatever value is set at launch will be used for the whole session.
The OS shouldn't matter... that was just a diagnostic step. As bloodbat says, I guess you'd be better off with a game-specific .conf file (or a frontend to manage that for you).

[ WEB ] - [ BLOG ] - [ TUBE ] - [ CODE ]

Reply 8 of 8, by lincruste

User metadata
Rank Newbie
Rank
Newbie

Understood. Thanks to both of you for your help and advice, I sure can live with game specific .conf files and restarts.
Regards,
mb