sm00thslp / hedgewars

Automatically exported from code.google.com/p/hedgewars
GNU General Public License v2.0
0 stars 0 forks source link

AI ignores crates when aiming? #538

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

This one is proving hard to reproduce. I've not noticed this occurring however 
in previous versions? I was playing another Highlander game against the AI on 
BambooPlinko.

What is the expected output? What do you see instead?

The AI aimed a cluster bomb at my hedgehog but didn't factor in the health 
crate that was in the way? The bomb instead hit the crate plumb and bounced off.

Note, the health crate was dropped near the beginning of the game. I've 
attached a screenshot.

What version of the product are you using? On what operating system?

0.9.19 alpha on Windows 7 64 bit

Original issue reported on code.google.com by jimithebear on 22 Feb 2013 at 12:47

Attachments:

GoogleCodeExporter commented 9 years ago
This exists in 0.9.18 too, and was deliberate.
The AI used to think crates were solid land, and when collecting a crate that 
was on the edge of something, esp if he had to drop down or jump to get it, 
would fall in the water and drown.

In 0.9.18, a bit was added to tag current hedgehog.  This allowed preventing 
grenades from being "thrown" into hedgehogs and allowed removing some prior 
workarounds.

This bit was extended to crates too, so that the AI would ignore them as valid 
terrain.

This prevents the AI from drowning or injuring himself in crate collection, but 
does mean he doesn't realise they block his shots.

A special case could be added in shot tracing so that the magic bit is ignored 
in shot tracing when distance from hedgehog's current position is greater than 
a certain amount (similar to the "test excluding me" thing).

It hasn't been too high a priority since, well, if he's using a bazooka or 
shotgun, he blows up the crate, which is denying it to the player and not too 
bad a result.  Plus is rare.

Original comment by kyberneticist@gmail.com on 22 Feb 2013 at 2:14

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Many thanks for the detailed explanation - very interesting point about the 
drowning! :)

Had that AI hedgehog used a shogun or bazooka however (in my screenshot 
scenario), the result may have been less fortunate due to wind direction?

I do like your workaround suggestion although will accept this isn't a frequent 
event.

Original comment by jimithebear on 8 Mar 2013 at 12:37