• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Need help with "simple" AI

Status
Not open for further replies.
Level 24
Joined
Aug 1, 2013
Messages
4,657
I am making a MOBA map atm and as I am close to call it v1.0, I started thinking about how to make AI so I can add bots.
This seems to be a bit harder than I expected and want to ask someone to help me with it.

Each player that is controlled by a computer needs an AI and it has to work when there are multiple heroes of the type they have.
They have only one hero cause it is a moba so that will make it easier.

If you want to, I don't have any offense against the AI made in JASS (As long as it is not vJASS.)

Ofc credits and +rep for those who help me.
 
Level 8
Joined
Jul 8, 2013
Messages
249
I've got some experience doing AIs so I could perhaps do one for you, but this is the kind of thing I would strongly recommend you do for yourself. Not only is knowing how to make an AI great for making lots of other maps you might work on, but also no one else will ever understand your map as well as you do and thus no one else can make the AI that does what you want as well as you can. Plus almost certainly you'll want to add new heroes or items or abilities or tweak the AI after you see it in practice and that will be way easier for you if you made the original AI version yourself.

I highly recommend this guide:

http://www.hiveworkshop.com/forums/trigger-gui-editor-tutorials-279/how-make-ai-your-map-245613/
 
Level 24
Joined
Aug 1, 2013
Messages
4,657
That system does seem to work good but it is not dynamic... I cannot use it for multiple units.
It does give me some ideas about how to make it though and will be of good use but if it will be enough I am not sure.

Anyway I will be starting AI once I got everything else finished so that will be this weekend probably. Then I will take a better look at it.
If anyone else has any tutorials or is able to help me with my project himself then please tell me.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
Google AoS AI. The map variant is "Aeon of Strife" (or sometimes miss-called DotA, Defence of the Ancients) so most tutorials refer to it as such. I have no idea where "MOBA "comes from but I believe stupid marketing guys called them "AoS" for decades before that term came about. They wanted something that sounds competitive and hip so they invented a term from nowhere.

Anyway the AI is pretty simple. Periodically you want to make a tactical decision which may or may not result in an order. The rate of 1 decision every second should be sufficient.

To make decisions usually some form of decision tree is used with various priorities. For example if health is less than 25% then always run back to base. I doubt Heroes of the Storm uses anything better than that sort of AI and it can be quite challenging if you have the right decisions.

You also need some form of "strategy" coordinator. Placing all AI on a single lane is not good so you need the ability to assign AI players to certain roles based on what is needed. Support/push heroes get assigned to lanes while damage and specialist heroes hop between lanes on demand.

A proper human like AI would use some kind of decision network to weigh up factors when making decisions rather than simple conditions. However such an AI is no easy task as even commercial games fail to use them.
 
Last edited:

Deleted member 219079

D

Deleted member 219079

Read dsg's answer.


There's great aps Ai here, use it instead of creating your own :)
 
Level 24
Joined
Aug 1, 2013
Messages
4,657
I have no idea where "MOBA "comes from but I believe stupid marketing guys called them "AoS" for decades before that term came about. They wanted something that sounds competitive and hip so they invented a term from nowhere.
MOBA (Multiplayer Online Battle Area) or ARTS (Action Real Time Strategy) are the game genres of games like AoS, DotA, Lol, Smite, etc.

It is the same relation as Call of Duty is a FPS (First Person Shooter) and WoW is a MMO RPG (Massive Multiplayer Online Role Playing Game)

Google AoS AI. The map variant is "Aeon of Strife" (or sometimes miss-called DotA, Defence of the Ancients) so most tutorials refer to it as such.
If I search that, most stuff I get is a discussion of what it does or what map has the best one.
A few are talking about how to make it but I don't get any information from those.
I also get some maps which are probably what you meant but I cannot check them right now -_- I will this afternoon though.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
MOBA (Multiplayer Online Battle Area) or ARTS (Action Real Time Strategy) are the game genres of games like AoS, DotA, Lol, Smite, etc.
No they are called AoS. DotA Allstars was the first very popular AoS. The MOBA nonsense was started by marketing by the one AoS standalone game that followed after Demigod but was surpassed later by League of Legends. I imagine calling them Aeons of Strife did not sound as enticing as some made up term. Or maybe it was League of LEgends that started it as I believe the one before called them ARTS. In either case the companies just made up terms for them to sound cool.

By the way, Battle Arenas have an entirely different meaning and are a completely unrelated sort of game. They generally are heroes put onto a map who have to wonder around killing creeps in FFA or team configurations. Victory is obtained either by time limit (most kills win) or lives (last survivor wins).

It is the same relation as Call of Duty is a FPS (First Person Shooter) and WoW is a MMO RPG (Massive Multiplayer Online Role Playing Game)
No it is like calling a FPS like Call of Duty a "Multiplayer Online Soldier Simulator" or MOSS. It is a made up term by marketing that totally disrespects its origins. If you come into WC3 modding asking for a MOBA most people have no idea what you are talking about as they are AoS maps. Some people incorrectly called them DotA style maps (generally the idiots who thought WC3 was only DotA Allstars) but that changed after Valve brought DotA.

The best AI I have seen is in the DotA Allstars AI version. With a full team of reasonably skilled players you will struggle to win reliably. You could try reverse engineering the AI by opening the map with a MPQ editor (I recommend MPQEdit as the new versions bypass the nonsense archive damaging some people did) and extracting the main script file.
 
Level 8
Joined
Jul 8, 2013
Messages
249
I have to disagree about the dota allstars AI being any kind of reasonable challenge- besides being newbish opponents at best, they make a couple of particularly huge and fatal mistakes which it would be wise to have your AI avoid:

1) They don't fear opponents who have crushed them before. They therefore will suicidally attack an opponent they have no chance against again and again and feed tremendously (I've played 1v5 games where I ended up with 200+ kills before finally making my drive for their ancient). I would suggest adding an if/then to your triggers checking how many times the AI has been defeated by a nearby foe vs how many times the AI hero has won. Have them flee or call for reinforcements if they ever have 2 more losses than wins and definitely flee if it looks like they're about to fight against 2 or more healthy opponents (maybe sum the % life of nearby enemies to check that.

2) they prioritize denies over last hits, leaving them impoverished. Every guide for every hero basically says you should focus on last hitting over denying; the AI just hasn't got the memo. This might or might not actually be a thing in your particular game.

3) They don't use the buddy system and are therefore easily divided and conquered. One major problem with WC AIs in almost every map is that it's easy to aggro just one enemy, lure it out alone, and murder it. Make your AIs run to group together with allies nearby if attacked alone. And make it so if one AI hero aggros onto an enemy, other AI heroes will approach and try to help.

4) They just do a ton of wholly useless and terrible stuff like jungling for huge amounts of time late game or running back to the fountain a lot to buy items.

The dota allstars AI tries to make up for this by cheating heavily, gaining huge bonuses to XP and gold unless you turn that mode off. This kind of AI crutch is to be avoided if possible. It won't really disguise a weak AI from any but a novice player. If you need to beef up your AI, I suggest using their strengths: impossible reflexes and calculation speed.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
The dota allstars AI tries to make up for this by cheating heavily, gaining huge bonuses to XP and gold unless you turn that mode off. This kind of AI crutch is to be avoided if possible. It won't really disguise a weak AI from any but a novice player. If you need to beef up your AI, I suggest using their strengths: impossible reflexes and calculation speed.
Maybe I was playing against the cheating AI. In any case they have insane micro skills. They do not constantly run back to the shops and when they do they buy everything instantly (unlike you who have to make sense of the gibberish item system and find where the mats are as nothing make sense). They also love mingling with mobs, running when injured and denying you kills which leaves you gold starved.

If you have a well balanced team its not an issue and you can often out smart them (they do not respond well to ambushes and have limited tactical ideas). However once you are a few kills down chances are they will land slide you being a higher level, with better items and more in-combat time. I do not think you can measure 1v5 as I believe the one player is given abnormal bonuses (more gold/exp?) so he will logically perform better. They key against them I found was to have at least 1 hero always in the front line of all lanes just to apply pressure and try and soften their mico.

In any case they beat the Heroes of the Storm AI massively. That AI seem to be lacking any form of ambush tactic currently making it very easy to surround them and perform a total team wipe out. Getting a kill streak of >20 is common sight and the AI often is 5 levels below you.
 
Level 8
Joined
Jul 8, 2013
Messages
249
make sense of the gibberish item system and find where the mats are as nothing make sense

I'm glad I'm not the only one who thinks dota's recipe system is bizarre and nonsensical. I've played it enough to know most of the recipes, but then every version or two they change one or move items around and it has to be re-learned.
 
I've played 1v5 games where I ended up with 200+ kills before finally making my drive for their ancient
Wow lol, at best I had 169. Creeps push too hard.

@DSG well, the Heroes AI is so bad. They don't even go back to base when low. They also prioritize getting hit and killing creeps.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
@DSG well, the Heroes AI is so bad. They don't even go back to base when low. They also prioritize getting hit and killing creeps.
Not the version I played. There they showed little mercy to lane hop and ambush me trying to run away. They also did their annoying "kill deny" stuff as well as running away when low on health back to the fountain to prevent you killing them.

I had the most luck using the sniper hero to kill them from a long range as their AI did not lower its run threshold to compensate for my >1000 range skills.

The map file name was "DotA v6.76c AI 1.1.3 En.w3x" and I played it with a few other people at the time.
 
Not the version I played. There they showed little mercy to lane hop and ambush me trying to run away. They also did their annoying "kill deny" stuff as well as running away when low on health back to the fountain to prevent you killing them.
Oh, must be another version from what I watched. Sounds okay.
 
Status
Not open for further replies.
Top