2020-08-04 08:49:11 +02:00
|
|
|
#include "common.h"
|
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", SetEncounterStatusFlags);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-09-24 05:16:13 +02:00
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_800441F0);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_80044238);
|
|
|
|
|
2020-08-16 08:55:51 +02:00
|
|
|
ApiStatus LoadDemoBattle(ScriptInstance* script, s32 isInitialCall) {
|
2020-08-10 07:03:56 +02:00
|
|
|
load_demo_battle(get_variable(script, *script->ptrReadPos));
|
2020-08-16 08:55:51 +02:00
|
|
|
return ApiStatus_DONE2;
|
2020-08-10 07:03:56 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
// ???
|
2020-08-16 08:55:51 +02:00
|
|
|
ApiStatus func_80044290(ScriptInstance* script, s32 isInitialCall) {
|
|
|
|
return ApiStatus_DONE2;
|
2020-08-10 07:03:56 +02:00
|
|
|
}
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", MakeNpcs);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", RemoveNpc);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", RemoveEncounter);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", GetBattleOutcome);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-09-24 05:16:13 +02:00
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_800445A8);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_800445D4);
|
|
|
|
|
2020-08-16 08:55:51 +02:00
|
|
|
ApiStatus GetOwnerEncountered(ScriptInstance* script, s32 isInitialCall) {
|
2020-08-10 07:03:56 +02:00
|
|
|
set_variable(script, *script->ptrReadPos, script->ownerActorID->encountered);
|
2020-08-16 08:55:51 +02:00
|
|
|
return ApiStatus_DONE2;
|
2020-08-10 07:03:56 +02:00
|
|
|
}
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", DoNpcDefeat);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_ASM("code_1f580_len_1940", start_battle);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-16 08:55:51 +02:00
|
|
|
ApiStatus StartBattle(ScriptInstance* script, s32 isInitialCall) {
|
2020-08-10 07:03:56 +02:00
|
|
|
start_battle(script, -1);
|
2020-08-16 08:55:51 +02:00
|
|
|
return ApiStatus_DONE1;
|
2020-08-10 07:03:56 +02:00
|
|
|
}
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-16 08:55:51 +02:00
|
|
|
ApiStatus StartBattleWith(ScriptInstance* script, s32 isInitialCall) {
|
2020-08-10 07:03:56 +02:00
|
|
|
start_battle(script, get_variable(script, *script->ptrReadPos));
|
2020-08-16 08:55:51 +02:00
|
|
|
return ApiStatus_DONE1;
|
2020-08-10 07:03:56 +02:00
|
|
|
}
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", StartBossBattle);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-09-07 23:12:31 +02:00
|
|
|
ApiStatus SetBattleMusic(ScriptInstance* script, s32 isInitialCall) {
|
|
|
|
Bytecode songID = get_variable(script, *script->ptrReadPos);
|
|
|
|
EncounterStatus* currentEncounter = &gCurrentEncounter;
|
|
|
|
|
|
|
|
currentEncounter->allowFleeing = 1;
|
|
|
|
currentEncounter->songID = songID;
|
|
|
|
currentEncounter->unk_18 = -1;
|
|
|
|
return ApiStatus_DONE2;
|
|
|
|
}
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", BindNpcAI);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", BindNpcIdle);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", RestartNpcAI);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", EnableNpcAI);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", SetNpcAux);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", BindNpcAux);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", RestartNpcAux);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", EnableNpcAux);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", BindNpcInteract);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", BindNpcHit);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", BindNpcDefeat);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", SetSelfVar);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", GetSelfVar);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", SetNpcVar);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", GetNpcVar);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", SetSelfRotation);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-16 08:55:51 +02:00
|
|
|
ApiStatus SetSelfEnemyFlags(ScriptInstance* script, s32 isInitialCall) {
|
2020-08-10 07:03:56 +02:00
|
|
|
script->ownerActorID->flags = *script->ptrReadPos;
|
2020-08-16 08:55:51 +02:00
|
|
|
return ApiStatus_DONE2;
|
2020-08-10 07:03:56 +02:00
|
|
|
}
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", SetSelfEnemyFlagBits);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-09-24 05:16:13 +02:00
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_80045580);
|
|
|
|
|
2020-08-16 08:55:51 +02:00
|
|
|
ApiStatus GetSelfNpcID(ScriptInstance* script, s32 isInitialCall) {
|
2020-08-10 07:03:56 +02:00
|
|
|
set_variable(script, *script->ptrReadPos, script->ownerActorID->npcID);
|
2020-08-16 08:55:51 +02:00
|
|
|
return ApiStatus_DONE2;
|
2020-08-10 07:03:56 +02:00
|
|
|
}
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", ClearDefeatedEnemies);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", SetEnemyFlagBits);
|
2020-08-04 08:49:11 +02:00
|
|
|
|
2020-09-24 05:16:13 +02:00
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_8004572C);
|
|
|
|
|
2020-08-17 19:44:41 +02:00
|
|
|
INCLUDE_API_ASM("code_1f580_len_1940", GetSelfAnimationFromTable);
|
2020-09-24 05:16:13 +02:00
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_80045798);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_800457C4);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_800457F8);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_8004580C);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_80045838);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_800458CC);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_80045900);
|
|
|
|
|
|
|
|
INCLUDE_ASM("code_1f580_len_1940", func_80045A58);
|