mirror of https://github.com/zeldaret/tmc.git
Name some things with NPC4E
This commit is contained in:
parent
2e21fde027
commit
a82ad2951a
|
@ -5,7 +5,7 @@ SCRIPT_START script_Npc4EFirstCloud
|
||||||
SetAnimationState 0x0004
|
SetAnimationState 0x0004
|
||||||
DoPostScriptAction 0x000b
|
DoPostScriptAction 0x000b
|
||||||
DoPostScriptAction 0x0008
|
DoPostScriptAction 0x0008
|
||||||
Call sub_0806DAAC
|
Call NPC4E_IsKinstoneFused
|
||||||
JumpIf script_0800D6AE
|
JumpIf script_0800D6AE
|
||||||
Call NPC4E_MakeFuserInteractable
|
Call NPC4E_MakeFuserInteractable
|
||||||
CallWithArg sub_0806DA04, 0x00000002
|
CallWithArg sub_0806DA04, 0x00000002
|
||||||
|
@ -13,7 +13,7 @@ SCRIPT_START script_Npc4EFirstCloud
|
||||||
script_0800D636:
|
script_0800D636:
|
||||||
_0807EA4C
|
_0807EA4C
|
||||||
_0807E9F0
|
_0807E9F0
|
||||||
Call sub_0806DAAC
|
Call NPC4E_IsKinstoneFused
|
||||||
JumpIf script_0800D650
|
JumpIf script_0800D650
|
||||||
Call EnablePauseMenu
|
Call EnablePauseMenu
|
||||||
EnablePlayerControl
|
EnablePlayerControl
|
||||||
|
@ -28,9 +28,9 @@ script_0800D650:
|
||||||
CameraTargetEntity
|
CameraTargetEntity
|
||||||
_0807EDD4 0x01e8, 0x01b8
|
_0807EDD4 0x01e8, 0x01b8
|
||||||
Wait 0x003c
|
Wait 0x003c
|
||||||
Call sub_0806DAE8
|
Call NPC4E_SetPinwheelFlag
|
||||||
Wait 0x0078
|
Wait 0x0078
|
||||||
Call sub_0806DB44
|
Call NPC4E_IsEveryPinwheelActivated
|
||||||
JumpIfNot script_Npc4EKinstoneFused
|
JumpIfNot script_Npc4EKinstoneFused
|
||||||
LoadRoomEntityList gUnk_080DD730
|
LoadRoomEntityList gUnk_080DD730
|
||||||
DoPostScriptAction 0x0006
|
DoPostScriptAction 0x0006
|
||||||
|
|
|
@ -3,7 +3,7 @@ SCRIPT_START script_MysteriousWall
|
||||||
BeginBlock
|
BeginBlock
|
||||||
DoPostScriptAction 0x000b
|
DoPostScriptAction 0x000b
|
||||||
DoPostScriptAction 0x0008
|
DoPostScriptAction 0x0008
|
||||||
Call sub_0806DAAC
|
Call NPC4E_IsKinstoneFused
|
||||||
JumpIf script_0800B9AC
|
JumpIf script_0800B9AC
|
||||||
Call NPC4E_MakeFuserInteractable
|
Call NPC4E_MakeFuserInteractable
|
||||||
CallWithArg sub_0806DA04, 0x00000005
|
CallWithArg sub_0806DA04, 0x00000005
|
||||||
|
|
|
@ -90,7 +90,7 @@ u8 NPC4E_GetKinstoneId(Entity* this) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check whether a kinstone fusion is possible and store the result somewhere in param_2?
|
// Check whether a kinstone fusion is possible and store the result somewhere in param_2?
|
||||||
void sub_0806DAAC(Entity* this, ScriptExecutionContext* context) {
|
void NPC4E_IsKinstoneFused(Entity* this, ScriptExecutionContext* context) {
|
||||||
context->condition = CheckKinstoneFused(NPC4E_GetKinstoneId(this));
|
context->condition = CheckKinstoneFused(NPC4E_GetKinstoneId(this));
|
||||||
gActiveScriptInfo.flags |= 1;
|
gActiveScriptInfo.flags |= 1;
|
||||||
}
|
}
|
||||||
|
@ -100,7 +100,7 @@ void NPC4E_MakeFuserInteractable(Entity* this) {
|
||||||
AddInteractableFuser(this, NPC4E_GetKinstoneId(this));
|
AddInteractableFuser(this, NPC4E_GetKinstoneId(this));
|
||||||
}
|
}
|
||||||
|
|
||||||
void sub_0806DAE8(Entity* this) {
|
void NPC4E_SetPinwheelFlag(Entity* this) {
|
||||||
switch (this->type - 1) {
|
switch (this->type - 1) {
|
||||||
case 0:
|
case 0:
|
||||||
SetLocalFlag(KUMOUE_02_AWASE_01);
|
SetLocalFlag(KUMOUE_02_AWASE_01);
|
||||||
|
@ -122,7 +122,7 @@ void sub_0806DAE8(Entity* this) {
|
||||||
SoundReq(SFX_TASK_COMPLETE);
|
SoundReq(SFX_TASK_COMPLETE);
|
||||||
}
|
}
|
||||||
|
|
||||||
void sub_0806DB44(Entity* this, ScriptExecutionContext* context) {
|
void NPC4E_IsEveryPinwheelActivated(Entity* this, ScriptExecutionContext* context) {
|
||||||
context->condition = 0;
|
context->condition = 0;
|
||||||
|
|
||||||
if (CheckLocalFlag(KUMOUE_02_AWASE_01) && CheckLocalFlag(KUMOUE_02_AWASE_02) &&
|
if (CheckLocalFlag(KUMOUE_02_AWASE_01) && CheckLocalFlag(KUMOUE_02_AWASE_02) &&
|
||||||
|
@ -148,29 +148,29 @@ void sub_0806DB84(Entity* this, ScriptExecutionContext* context) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
u32 sub_0806DBF4(u32 param_1) {
|
Item NPC4E_GetItemWithSwordUpgraded(Item itemId) {
|
||||||
switch (param_1) {
|
switch (itemId) {
|
||||||
case 1:
|
case ITEM_SMITH_SWORD:
|
||||||
case 2:
|
case ITEM_GREEN_SWORD:
|
||||||
case 3:
|
case ITEM_RED_SWORD:
|
||||||
case 4:
|
case ITEM_BLUE_SWORD:
|
||||||
case 6:
|
case ITEM_FOURSWORD:
|
||||||
param_1 = ITEM_SMITH_SWORD;
|
itemId = ITEM_SMITH_SWORD;
|
||||||
if (GetInventoryValue(ITEM_GREEN_SWORD) != 0) {
|
if (GetInventoryValue(ITEM_GREEN_SWORD) != 0) {
|
||||||
param_1 = ITEM_GREEN_SWORD;
|
itemId = ITEM_GREEN_SWORD;
|
||||||
}
|
}
|
||||||
if (GetInventoryValue(ITEM_RED_SWORD) != 0) {
|
if (GetInventoryValue(ITEM_RED_SWORD) != 0) {
|
||||||
param_1 = ITEM_RED_SWORD;
|
itemId = ITEM_RED_SWORD;
|
||||||
}
|
}
|
||||||
if (GetInventoryValue(ITEM_BLUE_SWORD) != 0) {
|
if (GetInventoryValue(ITEM_BLUE_SWORD) != 0) {
|
||||||
param_1 = ITEM_BLUE_SWORD;
|
itemId = ITEM_BLUE_SWORD;
|
||||||
}
|
}
|
||||||
if (GetInventoryValue(ITEM_FOURSWORD) != 0) {
|
if (GetInventoryValue(ITEM_FOURSWORD) != 0) {
|
||||||
param_1 = ITEM_FOURSWORD;
|
itemId = ITEM_FOURSWORD;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
return param_1;
|
return itemId;
|
||||||
}
|
}
|
||||||
|
|
||||||
void NPC4E_SaveEquippedItems(Entity* this) {
|
void NPC4E_SaveEquippedItems(Entity* this) {
|
||||||
|
@ -179,8 +179,8 @@ void NPC4E_SaveEquippedItems(Entity* this) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void NPC4E_RestoreEquippedItems(Entity* this) {
|
void NPC4E_RestoreEquippedItems(Entity* this) {
|
||||||
ForceEquipItem(sub_0806DBF4(this->field_0x68.HALF.LO), EQUIP_SLOT_A);
|
ForceEquipItem(NPC4E_GetItemWithSwordUpgraded(this->field_0x68.HALF.LO), EQUIP_SLOT_A);
|
||||||
ForceEquipItem(sub_0806DBF4(this->field_0x68.HALF.HI), EQUIP_SLOT_B);
|
ForceEquipItem(NPC4E_GetItemWithSwordUpgraded(this->field_0x68.HALF.HI), EQUIP_SLOT_B);
|
||||||
}
|
}
|
||||||
|
|
||||||
void sub_0806DC7C(void) {
|
void sub_0806DC7C(void) {
|
||||||
|
|
Loading…
Reference in New Issue