mirror of
https://github.com/zeldaret/tmc
synced 2026-07-01 20:20:22 -04:00
Add playeritem enum and use ids and kinds in all Findentity calls
This commit is contained in:
+3
-1
@@ -2,6 +2,7 @@
|
||||
#include "coord.h"
|
||||
#include "sound.h"
|
||||
#include "functions.h"
|
||||
#include "playeritem.h"
|
||||
|
||||
extern void (*const gUnk_0811BD98[])(ItemBehavior*, u32);
|
||||
|
||||
@@ -23,7 +24,8 @@ void sub_08075FF8(ItemBehavior* this, u32 arg1) {
|
||||
|
||||
if ((gPlayerState.jump_status | gPlayerState.field_0x3[1]) == 0) {
|
||||
bombCount = 0;
|
||||
for (entity = FindEntityByID(8, 2, 2); entity != NULL; entity = FindNextDuplicateID(entity, 2)) {
|
||||
for (entity = FindEntityByID(PLAYER_ITEM, PLAYER_ITEM_BOMB, 2); entity != NULL;
|
||||
entity = FindNextDuplicateID(entity, 2)) {
|
||||
bombCount += 1;
|
||||
}
|
||||
maxBombs = this->behaviorID == 7 ? 3 : 1;
|
||||
|
||||
@@ -112,7 +112,7 @@ void sub_080754B8(ItemBehavior* this, u32 arg1) {
|
||||
|
||||
if (gPlayerEntity.frameSpriteSettings & 1) {
|
||||
iVar1 = sub_0807B014();
|
||||
if (iVar1 && FindEntityByID(PLAYER_ITEM, 15, 2) == 0) {
|
||||
if (iVar1 && FindEntityByID(PLAYER_ITEM, PLAYER_ITEM_SWORD_BEAM1, 2) == 0) {
|
||||
CreatePlayerBomb(this, 0xf);
|
||||
if (iVar1 == 0xf) {
|
||||
gPlayerState.field_0xab = 5;
|
||||
|
||||
Reference in New Issue
Block a user