Important: This post is preserved only for historical reasons. It’s contents are out of date. To actually obtain the latest version of the script, please refer to the Defiance Autologin page.
I posted this on Reddit yesterday, but it seems folks there didn’t like the idea (or thought it would be an elaborate attempt at stealing their precious passwords), so it got buried in a flurry of downvotes. I’ll repost it here for all potential Google users. I use this script myself and can guarantee you it’s no trojan or anything – if in doubt, just check out the source yourself and compile your binary from there.
Anyway, when I bought Defiance a few days ago, I got immediately annoyed by the stupid launcher. Not only does it not save the password, it also requires multiple mouse clicks to log in. Considering Defiance can be played entirely with a controller, that’s pretty bad, since the computer I play on doesn’t even have a keyboard (all maintenance work is done via TeamViewer). It does have a mouse, but I prefer to use it as little as possible. Also, my password is complicated to a degree where most humans (and certainly not me) would be unable to remember it, so obviously, I prefer having not to enter it every time I want to play.
So I created a small script using AutoIt3 that can log you in automatically. Since the launcher is not following any kind of Windows UI standard, it does so by scanning the screen for specific graphical elements (the “Update” and “Play” buttons) and clicking them. The launcher is also a bit strange in that you have to actually move the mouse before the buttons become active, so the script is doing that for you as well.
First of all, a word of warning: Obviously, this stores your game password on your computer, which might not be a good idea to do for everyone. If you share access to your computer, or if you are paranoid (in a good way) about storing your password in plain text, please do not use this utility. This should be common sense, really. It should also be clear that you should not reuse passwords; make a special one for Defiance only and use this utility so you don’t need to remember it. I certainly take no responsibility when your password gets stolen because you used this script – it’s your own call. But unless your computer is already compromised, I wouldn’t know how that could happen.
With that out of the way, you can download either of two ZIP files:
Important: If you already have a previous version installed, please use the following update archive instead of reinstalling. The update includes both executable and source code (but only the changed files). Simply extract the update archive into your Defiance directory, overwriting files.
The current version is v1.02, released on May 26, 2013.
Unzip either archive into your Defiance directory, like in the following picture (the current version might have more or different files, but that’s okay, it’s still the same directory). What’s important is that you unzip into the directory where Patcher.exe resides.
Then, please open the file DefianceAutoLogin\DefianceAutoLogin.ini with Notepad (not Wordpad!) and edit it with your own login information. You’ll see the following structure:
UserName=enter your Defiance login name here
Password=enter your Defiance password here
Language=your desired language (en|de|fr)
You’ll need to enter your login name as well as your password. As language, you can set either en (English), de (German) or fr (French).
Important: Before using the Auto Login Script for the first time, you have to run the Defiance Launcher once to set your server region and language. The language setting in the launcher has to be identical to the one you put into the DefianceAutoLogin.ini!
After you’re done with editing the config file, just save it (Ctrl+S in Notepad) and close Notepad.
Now, you have two choices, depending on your level of courage and the archive you downloaded. If you downloaded the executable version, there should be a DefianceAutoLogin.exe, which you can run and sit back while it logs you into the game automatically.
If you downloaded the source only version (or are afraid of your password being stolen), you should first check out DefianceAutoLogin.au3, which is the source code for this utility. You will hopefully see that neither this file nor its include files (there might be some, depending on which version you have) include any code to steal your stuff. After you have confirmed that for yourself, you’ll need to download and install AutoIt3. During the installation, you’ll be asked what should happen when you double-click .au3 files – choose “run them”. After you’re done with that installation, you can either double-click DefianceAutoLogin.au3 every time you want to run Defiance, or compile your own executable by using the AutoIt3 script2exe utility.
Whatever you have chosen, from now on, run DefianceAutoLogin.exe or DefianceAutoLogin.au3 instead of Patcher.exe and watch the magic happen. Best would probably be to change the Defiance shortcut on your desktop.
Any questions can be asked in the comments, I’m happy to answer them.
v1.02 (2013-05-26) – Updated for patch 1.020. Now also closes the patcher after launching the game and prevents user interaction while entering login information.
v1.01 (2013-04-30) – Changed how the version of Patcher.exe is detected. Instead of scraping the screen, the script will now calculate a SHA1 hash of the file and compare it to a predefined value. This saves a few seconds on startup and is far more reliable. The older version still works, though, so there’s no need to update if you can’t be bothered.
v1.00 (2013-04-29) – Initial release