From cc80c858fc5d435fb36c8339a3667d971414ec5b Mon Sep 17 00:00:00 2001 From: BR Date: Sat, 27 Jan 2024 02:40:05 -0800 Subject: [PATCH] finish db_802262E0 --- src/melee/db/db_2253.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/melee/db/db_2253.c b/src/melee/db/db_2253.c index 928e2a40d6..65b2f9f81e 100644 --- a/src/melee/db/db_2253.c +++ b/src/melee/db/db_2253.c @@ -599,15 +599,16 @@ void db_802262E0(int player) OSReport("couldn't get Item struct.(CZako)"); return; } - if ((spawnItem.kind < 0xD0 || spawnItem.kind >= 0xEA || - it_804A0F60[spawnItem.kind] != 0) && - (spawnItem.kind != 0x22 || it_8026C704() == 0)) + if (spawnItem.kind < 0xD0 || spawnItem.kind >= 0xEA || + it_804A0F60[spawnItem.kind - 0xD0] != 0) { - { - HSD_GObj* gobj = Item_80268B18(&spawnItem); - if (gobj != NULL) { - GET_ITEM(gobj)->xDAA_flag.u8 |= db_804D6B3C; - efSync_Spawn(0x420, gobj, &spawnItem.prev_pos); + if (spawnItem.kind != 0x22 || it_8026C704() == 0) { + { + HSD_GObj* gobj = Item_80268B18(&spawnItem); + if (gobj != NULL) { + GET_ITEM(gobj)->xDAA_flag.u8 |= db_804D6B3C; + efSync_Spawn(0x420, gobj, &spawnItem.prev_pos); + } } } }