Bot level diferences and moves

16 replies [Last post]
francot514
User offline. Last seen 2 years 3 weeks ago. Offline
Joined: 2015-03-20
Posts: 163

Hi, i want to ask you about what are most important diferences between each bot level, and which moves can or cant use each of them, there is some config or limitations to weapons it can use==??

Wuzzy
Wuzzy's picture
User offline. Last seen 25 weeks 2 days ago. Offline
Joined: 2012-06-20
Posts: 1304

I bet nemo can help you on that one.

I don't know much about bots, but I know that higher-level bots actually do earn some additional capabilities. Low-level bots don't just aim worse, they are also a bit less intelligent (artificially dumbed down).
The only example I know is level 5 AI being capable of knocking barrels with a baseball bat towards enemies or something. Lower-level AI don't do that.

Also I know the AI is still far from being a serious player since there are many weapons and utilities which are simply off-limits for the AI (any level). The AI can't use rope, piano strike is not used, and so on.

Hi, I am a Hedgewars developer. Smile

nemo
nemo's picture
User offline. Last seen 19 weeks 4 days ago. Offline
Joined: 2009-01-28
Posts: 1861

I didn't get around to answering this 'cause it would basically involve checking all the tests on BotLevel in the AI files. But, yeah. lower level AI is unaware of drowning enemies, damaging/batting barrels to hurt other hogs, using cake/kamikaze/drill rocket. In general a low level AI basically uses shotgun/deagle/'zooka/'nade although I'd have to check the exact list, and has random error forcing its attacks to be less accurate.

Amusingly sometimes that error makes a shot more effective by causing it to hit a hog off centre and knock it into the water. But that's luck at low levels, not awareness of drowning trajectories.

At high levels he'll bat a hog extremely accurately into the water avoiding obstacles by a hair.

Low level AIs also have reduced movement. Like not being able to do jumps. Pretty sure they can't switch either.

--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev

KoBeWi
KoBeWi's picture
User offline. Last seen 1 week 11 hours ago. Offline
Joined: 2010-12-25
Posts: 565

Talking about knocking barrels, AI should be aware of damage modifiers. I've seen it many times when bot hit barrel with baseball and it exploded. This actually applies to other weapons, like Melon Bomb (cluster trajectory and stuff).

Also, high-level AI always uses Invincibility when it's unlimited, but I don't get why it does it just before attack. Again, I've seen bots (lv5) stepping in mines and losing turn, because they didn't use Invincibility from the start.

francot514
User offline. Last seen 2 years 3 weeks ago. Offline
Joined: 2015-03-20
Posts: 163

You mean the AI level determines some advanced movemements also, then based on this low level AI is useless, if you want to make good missions, guess you will better use advanced AI levels, unless you want to test something specific to the AI scripts??

nemo
nemo's picture
User offline. Last seen 19 weeks 4 days ago. Offline
Joined: 2009-01-28
Posts: 1861

kobwei, walking into mines and batting barrels that will explode sound like bugs. were these on snow level?
Could you share the demos?

--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev

KoBeWi
KoBeWi's picture
User offline. Last seen 1 week 11 hours ago. Offline
Joined: 2010-12-25
Posts: 565

I don't think I have demos for this.

Both bugs happened no matter the theme.

Barrel bug was when I had damage multiplier set in game settings. Enemy was hitting full-health barrel, but bat was just making too much damage.

Mine bug happened like 2 times. Once bot tried to jump over mine and failed and once I think the mine was on hill and bot got too close. Of course mine time was set to 0.

nemo
nemo's picture
User offline. Last seen 19 weeks 4 days ago. Offline
Joined: 2009-01-28
Posts: 1861

Ok. Yeah, if you aren't on "default" AI behaviour can get wonky. There's really not much time spent on non-default behaviour. It's hard enough to get it to do default. You're welcome to submit patches for things like mine time and damage modifier tho Wink Smiley

BTW, WRT AI and Lua, there's a flag unc0rr added to help AI play mutant better that tells it what hogs to target. You might find that handy in a script. There's a couple of the missions that oculd have benefitted from it (for "captive" hogs).
You can also use this flag to keep the AI from batting barrels in a script if they are going to explode.

--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev

francot514
User offline. Last seen 2 years 3 weeks ago. Offline
Joined: 2015-03-20
Posts: 163

Also there is a list of weapons AI should use or not, i want to clarify this please...

nemo
nemo's picture
User offline. Last seen 19 weeks 4 days ago. Offline
Joined: 2009-01-28
Posts: 1861

So that's a bit easier.
https://hg.hedgewars.org/hedgewars/file/tip/hedgewars/uAIAmmoTests.pas#l67

Weapons the AI can use are ones that there is a test written for, pretty much.

--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev

Wuzzy
Wuzzy's picture
User offline. Last seen 25 weeks 2 days ago. Offline
Joined: 2012-06-20
Posts: 1304

Translation to English:

The AI uses the following weapons:

  • Grenade
  • ClusterBomb
  • Bazooka
  • Bee
  • Shotgun
  • Desert Eagle
  • Dynamite
  • Shoryuken
  • Whip
  • Baseball Bat
  • Air Attack
  • Mortar
  • Kamikaze
  • Cake
  • Watermelon Bomb
  • Drill Rocket
  • Sniper Rifle
  • Molotov Cocktail
  • Old Limburger
  • Sine Gun
  • Sticky Mine
  • Hammer

The AI can also use vampirism (I guess) and invulnerability, but not always in a clever way. Every other weapon or utility will not be used as far I know.

Hi, I am a Hedgewars developer. Smile

KoBeWi
KoBeWi's picture
User offline. Last seen 1 week 11 hours ago. Offline
Joined: 2010-12-25
Posts: 565

Wuzzy allegedly wrote:
The AI can also use vampirism (I guess)

I've never seen it use this, even when it's infinite.

Wuzzy allegedly wrote:
and invulnerability

I mentioned it in my first post here. Also, it can use Extra Damage the same way.

nemo
nemo's picture
User offline. Last seen 19 weeks 4 days ago. Offline
Joined: 2009-01-28
Posts: 1861

https://hg.hedgewars.org/hedgewars/rev/ed70d59479d7

--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev

francot514
User offline. Last seen 2 years 3 weeks ago. Offline
Joined: 2015-03-20
Posts: 163

Wuzzy allegedly wrote:

The AI uses the following weapons:

The AI can also use vampirism (I guess) and invulnerability, but not always in a clever way. Every other weapon or utility will not be used as far I know.

Thanks for this useful info, so to be sure, will not needed any
schemes or scritps that add extra weapons to AI player, becuase those cannot be used.

nemo
nemo's picture
User offline. Last seen 19 weeks 4 days ago. Offline
Joined: 2009-01-28
Posts: 1861

just vampirism had been omitted. should be in next release of game

--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev

francot514
User offline. Last seen 2 years 3 weeks ago. Offline
Joined: 2015-03-20
Posts: 163

What is that script about, aia_Weapon is used variable?

UltiMaxKom
UltiMaxKom's picture
User offline. Last seen 4 years 44 weeks ago. Offline
Joined: 2016-06-26
Posts: 381

Please Fix this,,,
I HAVE A MODE THAT NEED THOSE DUMB AL BOTS !

My modes go sucks when bots gone Madness about hit some mines on the feet and many more,,,
They just fking weird for modes,,, please make their brains straight,,,

I still remember in Worms,, (no offense) Worms have Clever Bots that use Rope too,,,
and can kill enemy from afar (ya know,,, bazooka) , and teleport,,, these Al need Guides to use Teleport,,, ( actually not just teleport,,, they don't know about "What is Legs used for",,, i mean they don't know movement ( i mean, utilities )

╟───NW──────┼──────N╢

╓──────────────────╖ ╓──────────────────╖
⠀HP: ██████████ 1E9/1E91E9/1E9 ██████████ :MP
╙──────────────────╜ ╙──────────────────╜

User login

Copyright © 2004-2024 Hedgewars Project. All rights reserved. [ contact ]