Skip to content

Latest commit

 

History

History
42 lines (23 loc) · 4.53 KB

tools.md

File metadata and controls

42 lines (23 loc) · 4.53 KB

Tools

In order to start with bot development, you should be familiar with basic software tools that will help you to create, modify, debug and enhance your bot. Moreover, if you want to use these tools at most, you need to have an idea about how they work. This section will give you a short overview of the main tools that we are going to use during the bot development.

Programming Language

AutoIt is one of the most popular scripting programming languages for writing clicker bots. It has a lot of features that facilitate the development of automation scripts:

  1. Easy to learn syntax.
  2. Detailed online documentation and large community-based support forums.
  3. Smooth integration with WinAPI functions and third-party libraries.
  4. Built-in source code editor.

AutoIt is an excellent tool to start with programming. If you already have some experience with another programming language like C++, C#, Python, etc, you can use this language to implement examples from this chapter. Relevant WinAPI functions that are used by AutoIt will be mentioned.

AutoHotKey is a second scripting programming language that can be recommended for starting with game bots development. It has most of the AutoIt features but the syntax of this language is more unique. Some things will be simpler to implement with AutoHotKey than with AutoIt. But AutoHotKey language may be slightly more difficult to learn.

There are a lot of examples and guides about the development of game bots with both AutoIt and AutoHotKey languages on the Internet. Thus, you are free to choose a tool that you prefer. We will use AutoIt language in this chapter.

Image Processing Libraries

AutoIt itself has many powerful image analysis methods. But there are two third-party libraries that will be extremely helpful for our purposes:

  1. The ImageSearch library allows you to search a specified image in the game window.

  2. The FastFind library provides advanced methods for searching a specified pixel in the game window. You can specify the number of pixels of a given color. One of the FastFind library functions, for example, finds the regions where pixels of a given color are located as much close to each other as possible. Also, this library allows you to find the nearest pixel of a given color to the given point.

Image Analysis Tool

Possibility to check image parameters (like pixel color or pixel coordinates) is very helpful for a developer of clicker bots. It helps to debug a bot application and check if image processing algorithms work correctly.

There are plenty of tools that allow you to take the color of pixels from the screen and to get current coordinates of a mouse cursor. You can easily find these tools with Google. I use the ColorPix application that performs debugging tasks perfectly.

Source Code Editors

AutoIt language is distributed with the customized version of SciTE editor. It is a great editor for programming and debugging AutoIt scripts. But more universal editors like Notepad++ are more suitable if you use another programming language like Python or AutoHotKey. Microsoft Visual Studio is the best choice for developers who prefer C++ and C# languages.

API Hooking

We will develop example applications using high-level AutoIt language. The language encapsulates calls of WinAPI functions in the simplified interface. But it is necessary to know which WinAPI functions have been actually used by the internals of AutoIt. This allows you to understand algorithms better. Moreover, when you know the exact WinAPI function which was used, you can interact with it directly using your favorite programming language.

There are a lot of tools that provide WinAPI calls hooking. I use freeware API Monitor v2 application. It allows you to filter all hooked calls, to gather information about the process, to decode input and output parameters called functions and to view process memory. A full list of features is available on the developers website.