From 4571cf7fdce573df232345668b3dee3fc48f1892 Mon Sep 17 00:00:00 2001 From: Martin Michelsen Date: Wed, 11 Mar 2026 07:19:53 -0700 Subject: [PATCH] fix attribute count check in 6xDA --- src/ReceiveSubcommands.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ReceiveSubcommands.cc b/src/ReceiveSubcommands.cc index a234f509..ffce5eae 100644 --- a/src/ReceiveSubcommands.cc +++ b/src/ReceiveSubcommands.cc @@ -4440,7 +4440,7 @@ static asio::awaitable on_destroy_floor_item(shared_ptr c, Subcomm static asio::awaitable on_identify_item_bb(shared_ptr c, SubcommandMessage& msg) { auto l = c->require_lobby(); if (!l->is_game()) { - throw runtime_error("6xDA command sent in non-game lobby"); + throw runtime_error("6xB8 command sent in non-game lobby"); } if (c->version() == Version::BB_V4) { @@ -5391,7 +5391,7 @@ static asio::awaitable on_upgrade_weapon_attribute_bb(shared_ptr c } size_t attribute_index = 0; - for (size_t z = 6; z <= (item.has_kill_count() ? 10 : 8); z += 2) { + for (size_t z = 6; z <= (item.has_kill_count() ? 8 : 10); z += 2) { if ((item.data1[z] == 0) || (!(item.data1[z] & 0x80) && (item.data1[z] == cmd.attribute))) { attribute_index = z; break;