Every once and I while I will talk to someone who leaves their bots running during the day, and if it runs into a snag that they haven't programmatically accounted for already they are SoL.
Well that obviously doesn't have to be the case, there are two solutions:
1) Write your bot to answer literally every issue that could possible come up
2) Set up an non-intrusive remote desktop with alerts
Obviously the second option is better as long as you have internet access and don't want to troubleshoot every problem your bot could run into.
Remote Desktop
So the criteria we want in our virtual desktop are as follows:
- No resolution change
- No impeding the mouse and keyboard
- Ease of access
- Low idle bandwith (so Diablo III isn't lagging)
- No action on disconnect (No auto log off, no auto screensaver, etc.)
- Free!
The remote desktop application that I find to fit the criteria the best is LogMeIn.
https://secure.logmein.com/
The free version of LogMeIn requires a quick installation on the desktop of your home computer, which can then be access using the browser based application on the website. It is extremely convenient and effective. It also will allow you to access any website you want from work regardless of your web-filter without detection as long as you can access LogMeIn.com.
Configuration is straight forward but there are some important preferences
You HAVE to tell LogMeIn to never lock the host computer, those settings are found in the desktop application (Or on the remote access browser app)
If you have any questions about the rest of the setup process, ask and I'll include it in this mini-guide.
*You can stop right here if you don't mind checking your home desktop manually all day*
Notifications
"But Rhyno, I don't want to check my desktop every 30 minutes to make sure the bot is running"
Right, that's where notifications come in. There are a ton of elegant ways to set up notifications so I'll again share my favorite.
I will be using sendEmail and a Gmail account.
sendEmail is a command line application available for various operating system that lets you easily automate SMTP emails.
Installation is piss easy: Download the .exe and drop it into your windows installation folder (C:\Windows typically)
Now create a batch file named email.bat that will do the sending containing this line with the bold pieces replaced as appropriate:
Code:
sendEmail -f [sender]@gmail.com -t [recipient]@gmail.com -s smtp.gmail.com:587 -xu [G-mail username] -xp [G-mail Password] -u "[Email subject]" -m "[Email body]"
Give it a click and don't forget to check your spam folder.
If you are using an AutoIt bot with error handling (like chancity's) you can add this line wherever the error handling occurs
Make sure your email.bat is in the same folder as your script
For example:
Code:
Func TogglePause()
Run("email.bat")
$Paused = Not $Paused
While $Paused
Sleep(100)
WinSetTitle($title, "", $title & $ver & " - Paused")
ToolTip('[PAUSED] - Deaths: ' & $deathCount & ' | Cellars: ' & $cellarCount, 0, 0)
WEnd
WinSetTitle($title, "", $title & $ver & " - Running")
ToolTip("")
EndFunc ;==>TogglePause
That still requires you to predict where the bot will fail. A more reliable method is to convert the bat file to a screensaver. You can use Task Scheduling here too but it sucks and hardly ever works.
Creating a screensaver is really easy too:
1) Convert your .bat to an .exe, I use Bat To Exe Converter
2) Manually change the .exe extension to .scr
3) drop the .scr into C:\Windows\system32 or C:\Windows\sysWOW64 for 64 bit systems.
Now set it as your screensaver and enjoy getting an email every time your screensaver comes up.
tl;dr
1) Set up LogMeIn on your desktop and tell it to never lock the computer
2) Download SendEmail and drop it in C:\Windows
3) Create a .bat file that calls SendEmail
4) Convert the .bat file into an .exe, then rename it to a .scr
5) Drop the .scr into C:\Windows\System32 or your equivalent folder
6) Set the .scr as your screensaver