User Login

Help Community Login:

How to lock your mouse cursor within the Star Wars: The Old Republic game window when using multiple monitors

4 replies [Last post]
STaRDoGG's picture
From:
Olympus
STaRDoGG
Head Mucky MuckJoined the Dark SidePremium Member (Gold)I'm a Code Monkey!The Steel CurtainI use FirefoxI use Google ChromeI use Internet ExplorerI use SafariLinux UserMac UserWindows UserI donated to GeekDrop simply because I love it!Booga Booga BoogaI took a bite of the AppleFormer Phrozen Crew MemberI'm MagicMember of VileThe Dr. put the stem on the apple!The JokerSomeone thinks you're udderly delightful!
Relationship Status:
Single & Not Looking
Joined: 01/14/2009
Posts: 2622
Drops: 3109
Mood: Energetic

Ever play a game, like Star Wars: The Old Republic (SWTOR) on a multiple monitor setup, and accidentally click your mouse JUST past the edge of the screen by accident, causing the game to completely minimize? If you do this while playing SWTOR, it'll minimize to your taskbar, which you'll have to click on, which brings up a loading screen and then when it's done loading finally shows the game screen that you were on when you accidentally clicked off of it. This can be extremely aggravating if you're in the heat of PvP battle, or a Warzone, or maybe in a Flashpoint fighting a boss mob with friends, etc.

A friend contacted me asking if there was a way to stop this from happening, so I whipped up a quick little AutoIT script that works along side of Actual Multiple Monitors (AMM), an excellent multi-monitor software, that I've already been using for a while, and highly recommend if you run multiple monitors. Unfortunately, as of this article a key combination to be able to lock the mouse cursor within any window is available in AMM, however having it auto-detect any specific window (or game), auto-lock the mouse in that window, then stop so that it doesn't affect any other windows isn't available, and according to the friend who sent me this request, it's "only possible if you also purchase another software package" written by the same developers, as stated by a support request she sent to them.

What It Does:

So what this little script will do is very simple: you just use AMM as usual, and when you launch SWTOR it'll auto-detect the game running, automatically do the key combo to lock the mouse to within the SWTOR screen so you can't accidentally click outside of the game window, then exit the script. Very simple yet very convenient and effective. You'll no longer need to remember to run the key combo manually each time you start the game (usually only reminded by accidentally clicking off the screen, Laughing ).

How To Use It:

  1. The easiest way is to just download one of the pre-compiled game launchers (I made available both a 32-Bit version and a 64-Bit version, attached to the bottom of this article)

  2. Drop it into the same folder as the game (launcher.exe)

  3. Create a new shortcut to it. I've also included the regular swtor icon so that you can make the shortcut look exactly like the real one, if you choose to.

  4. Once you have the shortcut setup you're all done. Whenever you want to play the game just use the new shortcut, there's no interface to it so it'll look exactly like it usually does when you launch the game.

 
 

Another Option (not required):

I've also attached the raw script to this article so that you can edit it, or run it directly via the script if you have AutoIT3 installed.

Lastly:

Below is the actual source code, in case anyone is interested. You can copy/paste it directly into an AutoIT3 script as is, edit it, or use and abuse it to your hearts content. Obviously it's very easy to edit it to work the same within any other game or program.

; ================================================================================
;
; Star Wars: The Old Republic Game Launcher + Mouse Cursor locker
; Created by: GeekDrop.com / Scott Elblein / ThE STaRDoGG CHaMPioN [GD]
; 
; Requirements:
; Star Wars: The Old Republic game
; Actual Multiple Monitors - https://bit.ly/actual-multiple-monitors
; AutoIT3 (Only if you run the script version of this. If you use
;          the compiled .exe you don't need AutoIT)
;
; NOTE: There is NO user Interface to this. Just use it in place of your normal
;      shortcut to the game, while Actual Multiple Monitors is running.
;
; Instructions:
; Just place the compiled geekdrop-swtor-mouse-cursor-lock.exe in the same folder
; as your SWTOR's Launcher.exe and use it to always start the game instead of your
; usual shortcut.
;
; If you decide to use the script version instead, place this code in a new txt
; file, save it with a .au3 file extension in the same folder mentioned above,
; right-click on it whenever you want to launch the game, and choose Run Script
; from the menu. Of course to get that menu item you'll need AutoIT3 already 
; installed and working.
;
; ================================================================================
 
; Start the SWTOR Launcher, to enter credentials
Run("launcher.exe")
; Wait for up to 5 minutes, looking for the swtor.exe game client to appear
WinWait("[CLASS:PlayerClient]", "", 60000)
; Pause for 2 minutes, otherwise it's kind of hit or miss whether the Key Combo "takes"
Sleep(120)
; Activate it just to make sure it's at the front, so the Key Combo goes to the right place
WinActivate("Star Wars: The Old Republic")
; Send the Key Combo to lock the mouse cursor within the SWTOR Game window
Send("^!+l")
; All done here, no need to keep the script running
Exit
 

Enjoy!

 
I Averaged: 4 | 1 vote


Read More ...





AttachmentSize
geekdrop-swtor-mouse-cursor-lock.au31.76 KB
geekdrop-swtor-mouse-cursor-lock (x64).zip526.48 KB
geekdrop-swtor-mouse-cursor-lock (x32).zip430.6 KB

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
OliveOyl's picture
OliveOyl
Premium Member (Gold)I use FirefoxI use Internet ExplorerWindows UserI donated more than $20+ to GeekDrop!The Dr. left the stem off the apple!
Joined: 04/08/2009
Posts: 66
Drops: 127
Re: How to lock your mouse cursor within the Star Wars: The ...

Works perfect! I have a question, I prefer to use the "ignore" shortcut in AMM instead of the "lock" shortcut, so that I can still move my mouse outside of the game without it minimizing my game, can this be change to do that instead?

STaRDoGG's picture
From:
Olympus
STaRDoGG
Head Mucky MuckJoined the Dark SidePremium Member (Gold)I'm a Code Monkey!The Steel CurtainI use FirefoxI use Google ChromeI use Internet ExplorerI use SafariLinux UserMac UserWindows UserI donated to GeekDrop simply because I love it!Booga Booga BoogaI took a bite of the AppleFormer Phrozen Crew MemberI'm MagicMember of VileThe Dr. put the stem on the apple!The JokerSomeone thinks you're udderly delightful!
Relationship Status:
Single & Not Looking
Joined: 01/14/2009
Posts: 2622
Drops: 3109
Mood: Energetic
Re: How to lock your mouse cursor within the Star Wars: The ...
OliveOyl wrote:

I prefer to use the "ignore" shortcut in AMM instead of the "lock" shortcut, so that I can still move my mouse outside of the game without it minimizing my game, can this be change to do that instead?

I thought I had replied earlier to this question, but I guess I didn't? Doh!

You can very easily change it to do so, by just changing the "l" to an "i" in the script above (on the "Send..." line). That's all that's needed.



Shhh.. dont tell anyone, but we also have a private forum area with the really good stuff, see?

OliveOyl's picture
OliveOyl
Premium Member (Gold)I use FirefoxI use Internet ExplorerWindows UserI donated more than $20+ to GeekDrop!The Dr. left the stem off the apple!
Joined: 04/08/2009
Posts: 66
Drops: 127
Re: How to lock your mouse cursor within the Star Wars: The ...

Yaaay! I think the authors learned from your technique, they added it to AMM!!

Actual Multiple Monitors Changelog wrote:

[+] New
----------------------------------------------------
Actual Multiple Monitors 4.0 (13.03.2012)
----------------------------------------------------
[+] Compatibility mode is added for the Lock Mouse and Ignore Deactivation hotkeys (try to activate it if these hotkeys do not work by default for a particular game/application).
[+] Now it's possible to activate the Lock Mouse and Ignore Deactivation features automatically at specific window's startup.

i Heart the power of GeekDrop!! Big Grin

STaRDoGG's picture
From:
Olympus
STaRDoGG
Head Mucky MuckJoined the Dark SidePremium Member (Gold)I'm a Code Monkey!The Steel CurtainI use FirefoxI use Google ChromeI use Internet ExplorerI use SafariLinux UserMac UserWindows UserI donated to GeekDrop simply because I love it!Booga Booga BoogaI took a bite of the AppleFormer Phrozen Crew MemberI'm MagicMember of VileThe Dr. put the stem on the apple!The JokerSomeone thinks you're udderly delightful!
Relationship Status:
Single & Not Looking
Joined: 01/14/2009
Posts: 2622
Drops: 3109
Mood: Energetic
Re: How to lock your mouse cursor within the Star Wars: The ...

That's awesome. Smile

I've been developing software myself for so many years now (15 years!) that I've talked to and dealt with literally hundreds of other developers of popular software, and I've come to realize that 99% of them are usually quite friendly and more than willing to add new features if you just ask them directly or point out something to them that would enhance their software. Hopefully if the AMM dev(s) see this they'll hook me up with a free registration, since my trial period ran out! Laughing it really is a great piece of software, and the best multi-monitor software I've used, and I've tried em all.



Shhh.. dont tell anyone, but we also have a private forum area with the really good stuff, see?

Who's New

metaclippingpath's picture
Generalocee's picture
emma agro's picture
DarkkDdream's picture
Larisabrownb's picture
conor13's picture
MeadeDorianx's picture
Emilylowes's picture
Emmaythomson's picture
Chair's picture
Financial's picture
Red bud's picture
DonnaStella123's picture
WenrichFeugene's picture
Weissert's picture
facebook codes exploits tips tricks Phrozen Crew
All contents ©Copyright GeekDrop™ 2009-2024
TOS | Privacy Policy