Nostrademous / Dota2-FullOverwrite

Work in progress for a full-overwrite Dota 2 bot framework
GNU General Public License v3.0
97 stars 42 forks source link
bots dota2

This is a full bot over-write implementation. This means that for each hero (eventually all of them, but we start with small sample) we will implement a bot_<heroName>.lua file with an implementation of the Think() function.

This is a WORK IN PROGRESS. I share it in the hope that other developers will find it useful and potentially contribute by commiting pull requests against this code base building a better community bot framework.

Contributors The code representing this bot codebase is largely comprised of work of the author and many contributors of the "Dota 2 Bot Scripting Forums" which can be found here: Dota2 Dev Forum

These include: lenLRX, Platinum_dota2, ironmano, Keithen, and many others that I have lost track of.

Please drop me a message if you believe I have used your code and have not given the appropriate credit.

Getting Going:

To get going please visit this wiki page and the wiki in general.

If you want to contribute feel free to implement new heroes or improve existing code. You might want to file an issue first to make sure no one else is working on the exact same topic.

Make sure you checkout the next section (Code Layout and Common Patterns).

We'll appreciate any contributions!

Also: Lua is not hard to learn, and we'll gladly help if you're stuck. You can do it!

Code Layout and Common Patterns

The design intention was to largely leverage the concept of class-based inheritance as existant in Object Oriented Programming languagues, but in LUA.

There are files for each hero, and at least one file for each mode (for details, see below).

If you want to store some data for a bot, do so by using bot.<modeName>_<variableName>.

There are some stub files, just not for everything. Just copy the template file if one exist and open an implemented hero file similar to what you are looking to do for a boost to your productivity. The following stub files currently exist:

Heroes

While every hero has some files for itself, most of the logic is defined by generic modes (see below).

bot_<heroName>.lua:

abilityUse/abilityUse_<heroName>.lua:

itemPurchase/<heroName>.lua:

Modes

Modes contain generic concepts that can be used by every hero.

modes/<modeName>.lua:

modes/<modeName>_<heroName>.lua:

Files of Interest:

TODOs/FIXMEs:

Lots, we need :

A lot of FIXMEs/TODOs are commented in code - I add them as a tag to get back to with ideas.