Meeces to Pieces!


In my uikeys.txt file I’ve been trying to bind mouse button 4 on my Alienware Microsoft mouse so that the mouse cursor will change to ‘fight’ but without much success. I know about double clicking with the right mouse button for ‘fight’ so that all your troops fight to one single point on the map but that’s not really the effect I’m after. I’d like to be able to press and hold mouse button 4 while dragging the pointer, the same way you do with ‘move’ (right click and drag). Does anyone know how to do this?

On the Spring web site ( there is some info about mouse4 and 5 being used for buildspacing inc and dec so I tried to use mouse4 and 5 to increase or decrease the buildspacing as an experiment, to try and just get the buttons to respond, but my mouse buttons 4+5 would not work.

I have a feeling it might be my mouse but I’m not sure. If there isn’t a software solution can anyone recommend a mouse that they know will definitely work with Spring 1944: v1.53 Operation Market Garden, Spring version, on a 32bit Ubuntu 10.04 Lucid box please?

Mouse buttons can’t be bound with uikeys.txt (annoying I know).

What you need is a widget; This is the widget which binds mouse 4 and 5 to buildspacing: … pacing.lua

If you comment out line 19, uncomment line 18 and change it to


You should be in business. Also change the name on line 3 and save as some new filename into Spring/LuaUI/Widgets. If you have any difficulty let me know and I’ll do it for you. :wink:

Thank you FLOZi, that worked great! :slight_smile:

The only thing I had to change apart from the bits you’d previously mentioned was -

if (button == 4) then


if (button == 8) then

For some strange reason my Alienware Microsoft mouse has button 4 set up as button 8.

You’re welcome.

Have you had that issue anywhere else? May be a bug with how Spring detects mouse buttons.

No, I haven’t had any issues anywhere else with mouse 4+5.

I do not know the internals of the Spring engine but I would assume it scans the system at start-up for any attached hardware etc. and fills out some data structure with that info? So, is there perhaps a routine that the person who wrote the widget could have used to query that structure and detect the mouse buttons instead of hard coding them as 4+5?

On a different tangent, what is greedy waypoint mode please? In game I get the build buttons on the right side of the screen to turn green but that’s about it.

Are you referring to the ‘Waypoint Editor’ widget? If so, that’s for making map profiles for the CRAIG AI.