WillFlame14 / hanabi-bot

A bot that plays on the hanab.live interface.
GNU General Public License v3.0
14 stars 9 forks source link

not recognizing the bluff #265

Closed jhgravelle closed 3 weeks ago

jhgravelle commented 1 month ago

Version (PM the bot with /version): 1.4.6 Convention settings: 11 Steps to reproduce or replay link: https://hanab.live/shared-replay/1181528#13 Additional information:

bot 2 misses bluff

RandoPerso commented 1 month ago

There's actually two issues going on here:

  1. This bluff isn't even legal??? t2 connects to 3.
  2. bot2 does not react. This clue is a bluff through clued cards (the p2).

image

flackr commented 1 month ago

The invalid bluff due to it not being recognizable is intended to be recognized by resolve_bluff, specifically this part: https://github.com/WillFlame14/hanabi-bot/blob/master/src/conventions/h-group/clue-interpretation/connecting-cards.js#L212

The reason it failed to recognize it is that it currently only looks to see if the player who would play into the bluffed connection next would recognize it as a bluff (to know not to play), and indeed will-bot2 would know that it was a bluff after playing t2, expecting a p1. However, what that code does not consider is that will-bot4 despite not being the next in the intended connection would see t2 as leading to the clued 3.

flackr commented 4 weeks ago

It turned out to be a bit trickier, we can't determine it in resolve_bluff because resolve_bluff is only looking at one particular connection to the focused card and we need to consider all other interpretations, hence the new finalize_bluff which is really just a unification of what we ran for finding bluffs in your own hand already.