mirror of
https://github.com/zeldaret/mm.git
synced 2026-08-06 18:02:22 -04:00
item_inbox OK (#95)
* item_inbox OK * renamed func_80945534 to suggested name
This commit is contained in:
@@ -9,7 +9,8 @@ void ItemInbox_Destroy(Actor* thisx, GlobalContext* globalCtx);
|
||||
void ItemInbox_Update(Actor* thisx, GlobalContext* globalCtx);
|
||||
void ItemInbox_Draw(Actor* thisx, GlobalContext* globalCtx);
|
||||
|
||||
/*
|
||||
void ItemInbox_Idle(ItemInbox* this, GlobalContext* globalCtx);
|
||||
|
||||
const ActorInit Item_Inbox_InitVars = {
|
||||
ACTOR_ITEM_INBOX,
|
||||
ACTORCAT_NPC,
|
||||
@@ -21,14 +22,33 @@ const ActorInit Item_Inbox_InitVars = {
|
||||
(ActorFunc)ItemInbox_Update,
|
||||
(ActorFunc)ItemInbox_Draw
|
||||
};
|
||||
*/
|
||||
|
||||
#pragma GLOBAL_ASM("./asm/non_matchings/overlays/ovl_Item_Inbox_0x809454F0/ItemInbox_Init.asm")
|
||||
void ItemInbox_Init(Actor* thisx, GlobalContext* globalCtx) {
|
||||
ItemInbox* this = THIS;
|
||||
|
||||
#pragma GLOBAL_ASM("./asm/non_matchings/overlays/ovl_Item_Inbox_0x809454F0/ItemInbox_Destroy.asm")
|
||||
this->actionFunc = ItemInbox_Idle;
|
||||
Actor_SetScale(&this->actor, 0.2f);
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("./asm/non_matchings/overlays/ovl_Item_Inbox_0x809454F0/func_80945534.asm")
|
||||
void ItemInbox_Destroy(Actor* thisx, GlobalContext* globalCtx) {
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("./asm/non_matchings/overlays/ovl_Item_Inbox_0x809454F0/ItemInbox_Update.asm")
|
||||
void ItemInbox_Idle(ItemInbox* this, GlobalContext* globalCtx) {
|
||||
if (Actor_GetChestFlag(globalCtx, (this->actor.params >> 8) & 0x1F)) {
|
||||
Actor_MarkForDeath(&this->actor);
|
||||
}
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("./asm/non_matchings/overlays/ovl_Item_Inbox_0x809454F0/ItemInbox_Draw.asm")
|
||||
void ItemInbox_Update(Actor* thisx, GlobalContext* globalCtx) {
|
||||
ItemInbox* this = THIS;
|
||||
|
||||
this->actionFunc(this, globalCtx);
|
||||
}
|
||||
|
||||
void ItemInbox_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
||||
ItemInbox* this = THIS;
|
||||
|
||||
func_800B8050(&this->actor, globalCtx, 0);
|
||||
func_800B8118(&this->actor, globalCtx, 0);
|
||||
GetItem_Draw(globalCtx, this->actor.params & 0xFF);
|
||||
}
|
||||
|
||||
@@ -5,9 +5,11 @@
|
||||
|
||||
struct ItemInbox;
|
||||
|
||||
typedef void (*ItemInboxActionFunc)(struct ItemInbox*, GlobalContext*);
|
||||
|
||||
typedef struct ItemInbox {
|
||||
/* 0x000 */ Actor actor;
|
||||
/* 0x144 */ char unk_144[0x4];
|
||||
/* 0x144 */ ItemInboxActionFunc actionFunc;
|
||||
} ItemInbox; // size = 0x148
|
||||
|
||||
extern const ActorInit Item_Inbox_InitVars;
|
||||
|
||||
Reference in New Issue
Block a user