From be83cafe0d45c8edf8bfe62221b8a3f8b1561e15 Mon Sep 17 00:00:00 2001 From: Martin Michelsen Date: Thu, 30 Mar 2023 17:49:21 -0700 Subject: [PATCH] check for BB restoration items in ItemCreator --- src/ItemCreator.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ItemCreator.cc b/src/ItemCreator.cc index 6f3d7659..e801b158 100644 --- a/src/ItemCreator.cc +++ b/src/ItemCreator.cc @@ -429,8 +429,12 @@ void ItemCreator::clear_item_if_restricted(ItemData& item) const { if (this->mode == GameMode::CHALLENGE) { // Forbid HP/TP-restoring units and meseta in challenge mode + // Note: PSO GC doesn't check for 0x61 or 0x62 here since those items + // (HP/Resurrection and TP/Resurrection) only exist on BB. if (item.data1[0] == 1) { - if ((item.data1[1] == 3) && (item.data1[2] >= 0x33) && (item.data1[2] <= 0x38)) { + if ((item.data1[1] == 3) && ( + ((item.data1[2] >= 0x33) && (item.data1[2] <= 0x38)) || + (item.data1[2] == 0x61) || (item.data1[2] == 0x62))) { this->log.info("Restricted: restore items not allowed in Challenge mode"); item.clear(); }