feat(BNNBot): add virtual hit percentage to output

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-09-17 23:54:31 +02:00
parent 481f284e1a
commit e600204c84
2 changed files with 4 additions and 1 deletions
Binary file not shown.
+4 -1
View File
@@ -133,10 +133,13 @@ method onScannedBot*(bot: BNNBot, e: ScannedBotEvent) =
let hamming = if bot.hasPrev: hammingDistance(bot.prevVec, vec) else: 0
let similarity = if bot.hasPrev: TOTAL_BITS - hamming else: 0
let overlap = if bot.hasPrev: popcount(bitwiseAnd(bot.prevVec, vec)) else: 0
let totalVirtual = bot.virtualHits + bot.virtualMiss
let hitPct = if totalVirtual > 0: bot.virtualHits.float / totalVirtual.float * 100.0 else: 0.0
echo align($bot.tick, 4), " ", formatBinary(vec), " ",
hamming, " ", similarity, " ", overlap, " ",
formatFloat(aimOffset, ffDecimal, 2), " ",
bot.virtualHits, " ", bot.virtualMiss
bot.virtualHits, " ", bot.virtualMiss, " ",
formatFloat(hitPct, ffDecimal, 1), "%"
bot.prevVec = vec
bot.hasPrev = true