Merge pull request #2906 from HarbourMasters/develop-spock

Spock -> develop
This commit is contained in:
Christopher Leggett 2023-05-23 09:18:15 -04:00 committed by GitHub
commit fe6705cc4d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
149 changed files with 448 additions and 85 deletions

View File

@ -5,12 +5,13 @@ set(CMAKE_CXX_STANDARD 20 CACHE STRING "The C++ standard to use")
set(CMAKE_OSX_DEPLOYMENT_TARGET "10.15" CACHE STRING "Minimum OS X deployment version")
project(Ship VERSION 7.0.1 LANGUAGES C CXX)
set(PROJECT_BUILD_NAME "Spock Bravo" CACHE STRING "")
project(Ship VERSION 7.0.2 LANGUAGES C CXX)
set(PROJECT_BUILD_NAME "Spock Charlie" CACHE STRING "")
set(PROJECT_TEAM "github.com/harbourmasters" CACHE STRING "")
set_property(DIRECTORY ${CMAKE_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT soh)
add_compile_options($<$<CXX_COMPILER_ID:MSVC>:/MP>)
add_compile_options($<$<CXX_COMPILER_ID:MSVC>:/utf-8>)
if (CMAKE_SYSTEM_NAME MATCHES "Windows|Linux")
if(NOT DEFINED BUILD_CROWD_CONTROL)

View File

@ -500,6 +500,7 @@ if(MSVC)
/INCREMENTAL:NO;
/FORCE:MULTIPLE
>
/MANIFEST:NO;
/DEBUG;
/SUBSYSTEM:WINDOWS
)
@ -514,6 +515,7 @@ if(MSVC)
/INCREMENTAL:NO;
/FORCE:MULTIPLE
>
/MANIFEST:NO;
/DEBUG;
/SUBSYSTEM:WINDOWS
)

View File

@ -91,6 +91,13 @@ END
// remains consistent on all systems.
IDI_ICON1 ICON "SHIPOFHARKINIAN.ico"
/////////////////////////////////////////////////////////////////////////////
//
// RT_MANIFEST
//
1 RT_MANIFEST "SHIPOFHARKINIAN.manifest"
#endif // English (United States) resources
/////////////////////////////////////////////////////////////////////////////

View File

@ -0,0 +1,31 @@
<?xml version='1.0' encoding='UTF-8' standalone='yes'?>
<assembly xmlns='urn:schemas-microsoft-com:asm.v1' manifestVersion='1.0'>
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Common-Controls"
version="6.0.0.0"
publicKeyToken="6595b64144ccf1df"
language="*"
processorArchitecture="*" />
</dependentAssembly>
</dependency>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level='asInvoker' uiAccess='false' />
</requestedPrivileges>
</security>
</trustInfo>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<!-- Windows 8 -->
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />
<!-- Windows 8.1 -->
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />
<!-- Windows 10 -->
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
</application>
</compatibility>
</assembly>

View File

@ -103,6 +103,7 @@ extern "C"
extern u32 gGsFlagsShifts[4];
extern void* gItemIcons[0x82];
extern u8 gItemAgeReqs[];
extern u8 gSlotAgeReqs[];
extern u8 gItemSlots[56];
extern void (*gSceneCmdHandlers[SCENE_CMD_ID_MAX])(PlayState*, SceneCmd*);
extern s16 gLinkObjectIds[2];

View File

@ -267,10 +267,10 @@ namespace GameControlEditor {
UIWidgets::PaddedEnhancementCheckbox("Invert Camera Y Axis", "gInvertYAxis", true, true, false, "", UIWidgets::CheckboxGraphics::Cross, true);
DrawHelpIcon("Inverts the Camera Y Axis in:\n-Free camera");
UIWidgets::Spacer(0);
+ UIWidgets::PaddedEnhancementSliderFloat("Third-Person Horizontal Sensitivity: %d %%", "##ThirdPersonSensitivity Horizontal",
+ "gThirdPersonCameraSensitivityX", 0.01f, 5.0f, "", 1.0f, true, true, false, true);
+ UIWidgets::PaddedEnhancementSliderFloat("Third-Person Vertical Sensitivity: %d %%", "##ThirdPersonSensitivity Vertical",
+ "gThirdPersonCameraSensitivityY", 0.01f, 5.0f, "", 1.0f, true, true, false, true);
UIWidgets::PaddedEnhancementSliderFloat("Third-Person Horizontal Sensitivity: %d %%", "##ThirdPersonSensitivity Horizontal",
"gThirdPersonCameraSensitivityX", 0.01f, 5.0f, "", 1.0f, true, true, false, true);
UIWidgets::PaddedEnhancementSliderFloat("Third-Person Vertical Sensitivity: %d %%", "##ThirdPersonSensitivity Vertical",
"gThirdPersonCameraSensitivityY", 0.01f, 5.0f, "", 1.0f, true, true, false, true);
UIWidgets::PaddedEnhancementSliderInt("Camera Distance: %d", "##CamDist",
"gFreeCameraDistMax", 100, 900, "", 185, true, false, true);
UIWidgets::PaddedEnhancementSliderInt("Camera Transition Speed: %d", "##CamTranSpeed",

View File

@ -1,40 +1,46 @@
#include "GameInteractor.h"
#ifdef __cplusplus
extern "C" {
#endif
// MARK: - Gameplay
extern "C" void GameInteractor_ExecuteOnLoadGame(int32_t fileNum);
extern "C" void GameInteractor_ExecuteOnExitGame(int32_t fileNum);
extern "C" void GameInteractor_ExecuteOnGameFrameUpdate();
extern "C" void GameInteractor_ExecuteOnItemReceiveHooks(GetItemEntry itemEntry);
extern "C" void GameInteractor_ExecuteOnSaleEndHooks(GetItemEntry itemEntry);
extern "C" void GameInteractor_ExecuteOnTransitionEndHooks(int16_t sceneNum);
extern "C" void GameInteractor_ExecuteOnSceneInit(int16_t sceneNum);
extern "C" void GameInteractor_ExecuteOnSceneSpawnActors();
extern "C" void GameInteractor_ExecuteOnPlayerUpdate();
extern "C" void GameInteractor_ExecuteOnOcarinaSongAction();
extern "C" void GameInteractor_ExecuteOnActorUpdate(void* actor);
extern "C" void GameInteractor_ExecuteOnPlayerBonk();
extern "C" void GameInteractor_ExecuteOnOcarinaSongAction();
void GameInteractor_ExecuteOnLoadGame(int32_t fileNum);
void GameInteractor_ExecuteOnExitGame(int32_t fileNum);
void GameInteractor_ExecuteOnGameFrameUpdate();
void GameInteractor_ExecuteOnItemReceiveHooks(GetItemEntry itemEntry);
void GameInteractor_ExecuteOnSaleEndHooks(GetItemEntry itemEntry);
void GameInteractor_ExecuteOnTransitionEndHooks(int16_t sceneNum);
void GameInteractor_ExecuteOnSceneInit(int16_t sceneNum);
void GameInteractor_ExecuteOnSceneSpawnActors();
void GameInteractor_ExecuteOnPlayerUpdate();
void GameInteractor_ExecuteOnOcarinaSongAction();
void GameInteractor_ExecuteOnActorUpdate(void* actor);
void GameInteractor_ExecuteOnPlayerBonk();
void GameInteractor_ExecuteOnOcarinaSongAction();
// MARK: - Save Files
extern "C" void GameInteractor_ExecuteOnSaveFile(int32_t fileNum);
extern "C" void GameInteractor_ExecuteOnLoadFile(int32_t fileNum);
extern "C" void GameInteractor_ExecuteOnDeleteFile(int32_t fileNum);
void GameInteractor_ExecuteOnSaveFile(int32_t fileNum);
void GameInteractor_ExecuteOnLoadFile(int32_t fileNum);
void GameInteractor_ExecuteOnDeleteFile(int32_t fileNum);
// MARK: - Dialog
extern "C" void GameInteractor_ExecuteOnDialogMessage();
extern "C" void GameInteractor_ExecuteOnPresentTitleCard();
extern "C" void GameInteractor_ExecuteOnInterfaceUpdate();
extern "C" void GameInteractor_ExecuteOnKaleidoscopeUpdate(int16_t inDungeonScene);
void GameInteractor_ExecuteOnDialogMessage();
void GameInteractor_ExecuteOnPresentTitleCard();
void GameInteractor_ExecuteOnInterfaceUpdate();
void GameInteractor_ExecuteOnKaleidoscopeUpdate(int16_t inDungeonScene);
// MARK: - Main Menu
extern "C" void GameInteractor_ExecuteOnPresentFileSelect();
extern "C" void GameInteractor_ExecuteOnUpdateFileSelectSelection(uint16_t optionIndex);
extern "C" void GameInteractor_ExecuteOnUpdateFileCopySelection(uint16_t optionIndex);
extern "C" void GameInteractor_ExecuteOnUpdateFileCopyConfirmationSelection(uint16_t optionIndex);
extern "C" void GameInteractor_ExecuteOnUpdateFileEraseSelection(uint16_t optionIndex);
extern "C" void GameInteractor_ExecuteOnUpdateFileEraseConfirmationSelection(uint16_t optionIndex);
extern "C" void GameInteractor_ExecuteOnUpdateFileAudioSelection(uint8_t optionIndex);
extern "C" void GameInteractor_ExecuteOnUpdateFileTargetSelection(uint8_t optionIndex);
void GameInteractor_ExecuteOnPresentFileSelect();
void GameInteractor_ExecuteOnUpdateFileSelectSelection(uint16_t optionIndex);
void GameInteractor_ExecuteOnUpdateFileCopySelection(uint16_t optionIndex);
void GameInteractor_ExecuteOnUpdateFileCopyConfirmationSelection(uint16_t optionIndex);
void GameInteractor_ExecuteOnUpdateFileEraseSelection(uint16_t optionIndex);
void GameInteractor_ExecuteOnUpdateFileEraseConfirmationSelection(uint16_t optionIndex);
void GameInteractor_ExecuteOnUpdateFileAudioSelection(uint8_t optionIndex);
void GameInteractor_ExecuteOnUpdateFileTargetSelection(uint8_t optionIndex);
// MARK: - Game
extern "C" void GameInteractor_ExecuteOnSetGameLanguage();
void GameInteractor_ExecuteOnSetGameLanguage();
#ifdef __cplusplus
}
#endif

View File

@ -646,6 +646,7 @@ void SetupDisplayNames() {
strcpy(itemTimestampDisplayName[TIMESTAMP_DEFEAT_TWINROVA], "Twinrova Defeated: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_DEFEAT_GANONDORF], "Ganondorf Defeated: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_DEFEAT_GANON], "Ganon Defeated: ");
strcpy(itemTimestampDisplayName[TIMESTAMP_FOUND_GREG], "Greg Found: ");
}
void SetupDisplayColors() {

View File

@ -486,6 +486,24 @@ void RegisterBonkDamage() {
});
}
void UpdateDirtPathFixState(int32_t sceneNum) {
switch (sceneNum) {
case SCENE_SPOT00:
case SCENE_SPOT04:
case SCENE_SPOT15:
CVarSetInteger("gDirtPathFix", CVarGetInteger("gSceneSpecificDirtPathFix", 0));
return;
default:
CVarClear("gDirtPathFix");
}
}
void RegisterMenuPathFix() {
GameInteractor::Instance->RegisterGameHook<GameInteractor::OnTransitionEnd>([](int32_t sceneNum) {
UpdateDirtPathFixState(sceneNum);
});
}
void InitMods() {
RegisterTTS();
RegisterInfiniteMoney();
@ -504,4 +522,5 @@ void InitMods() {
RegisterRupeeDash();
RegisterHyperBosses();
RegisterBonkDamage();
RegisterMenuPathFix();
}

View File

@ -1,3 +1,5 @@
#include <stdint.h>
#ifndef MODS_H
#define MODS_H
@ -5,6 +7,7 @@
extern "C" {
#endif
void UpdateDirtPathFixState(int32_t sceneNum);
void InitMods();
#ifdef __cplusplus

View File

@ -518,7 +518,7 @@ std::string GenerateRandomizer(std::unordered_map<RandomizerSettingKey, uint8_t>
srand(time(NULL));
// if a blank seed was entered, make a random one
if (seedString.empty()) {
Settings::seed = rand() & 0xFFFFFFFF;
seedString = std::to_string(rand() % 0xFFFFFFFF);
} else if (seedString.rfind("seed_testing_count", 0) == 0 && seedString.length() > 18) {
int count;
try {
@ -530,16 +530,11 @@ std::string GenerateRandomizer(std::unordered_map<RandomizerSettingKey, uint8_t>
}
Playthrough::Playthrough_Repeat(cvarSettings, excludedLocations, count);
return "";
} else {
try {
uint32_t seedHash = boost::hash_32<std::string>{}(seedString);
int seed = seedHash & 0xFFFFFFFF;
Settings::seed = seed;
}
Settings::seedString = seedString;
} catch (...) {
return "";
}
}
uint32_t seedHash = boost::hash_32<std::string>{}(Settings::seedString);
Settings::seed = seedHash & 0xFFFFFFFF;
int ret = Playthrough::Playthrough_Init(Settings::seed, cvarSettings, excludedLocations);
if (ret < 0) {

View File

@ -87,8 +87,9 @@ int Playthrough_Repeat(std::unordered_map<RandomizerSettingKey, uint8_t> cvarSet
printf("\x1b[0;0HGENERATING %d SEEDS", count);
uint32_t repeatedSeed = 0;
for (int i = 0; i < count; i++) {
repeatedSeed = rand() % 0xFFFFFFFF;
Settings::seed = repeatedSeed;
Settings::seedString = std::to_string(rand() % 0xFFFFFFFF);
repeatedSeed = boost::hash_32<std::string>{}(Settings::seedString);
Settings::seed = repeatedSeed % 0xFFFFFFFF;
CitraPrint("testing seed: " + std::to_string(Settings::seed));
ClearProgress();
Playthrough_Init(Settings::seed, cvarSettings, excludedLocations);

View File

@ -3150,7 +3150,7 @@ void DrawRandoEditor(bool& open) {
UIWidgets::Spacer(0);
if (ImGui::Button("Generate Randomizer")) {
GenerateRandomizer(CVarGetInteger("gRandoManualSeedEntry", 0) ? seedString : std::to_string(rand() & 0xFFFFFFFF).c_str());
GenerateRandomizer(CVarGetInteger("gRandoManualSeedEntry", 0) ? seedString : "");
}
UIWidgets::Spacer(0);

View File

@ -222,9 +222,9 @@ void Extractor::GetRoms(std::vector<std::string>& roms) {
if (S_ISREG(path.st_mode)) {
// Get the position of the extension character.
char* ext = strchr(dir->d_name, '.');
if (ext != NULL && (strcmp(ext, ".z64") == 0) && (strcmp(ext, ".n64") == 0) &&
(strcmp(ext, ".v64") == 0)) {
char* ext = strrchr(dir->d_name, '.');
if (ext != NULL && (strcmp(ext, ".z64") == 0 || strcmp(ext, ".n64") == 0 ||
strcmp(ext, ".v64") == 0)) {
roms.push_back(dir->d_name);
}
}

View File

@ -29,6 +29,7 @@
#include "soh/SaveManager.h"
#include "OTRGlobals.h"
#include "soh/Enhancements/presets.h"
#include "soh/Enhancements/mods.h"
#include "soh/resource/type/Skeleton.h"
#ifdef ENABLE_CROWD_CONTROL
@ -46,6 +47,8 @@ extern "C" {
void disableBetaQuest() { isBetaQuestEnabled = false; }
}
extern "C" PlayState* gPlayState;
enum SeqPlayers {
/* 0 */ SEQ_BGM_MAIN,
/* 1 */ SEQ_FANFARE,
@ -860,7 +863,9 @@ namespace GameMenuBar {
ImGui::EndMenu();
}
UIWidgets::PaddedText("Fix Vanishing Paths", true, false);
UIWidgets::EnhancementCombobox("gDirtPathFix", zFightingOptions, 0);
if (UIWidgets::EnhancementCombobox("gSceneSpecificDirtPathFix", zFightingOptions, 0) && gPlayState != NULL) {
UpdateDirtPathFixState(gPlayState->sceneNum);
}
UIWidgets::Tooltip("Disabled: Paths vanish more the higher the resolution (Z-fighting is based on resolution)\n"
"Consistent: Certain paths vanish the same way in all resolutions\n"
"No Vanish: Paths do not vanish, Link seems to sink in to some paths\n"

View File

@ -689,9 +689,10 @@ std::unordered_map<uint32_t, uint32_t> ItemIDtoGetItemID{
{ ITEM_WEIRD_EGG, GI_WEIRD_EGG }
};
extern "C" uint32_t GetGIID(uint32_t itemID) {
if (ItemIDtoGetItemID.contains(itemID))
extern "C" int32_t GetGIID(uint32_t itemID) {
if (ItemIDtoGetItemID.contains(itemID)) {
return ItemIDtoGetItemID.at(itemID);
}
return -1;
}
@ -782,6 +783,8 @@ extern "C" void InitOTR() {
} else {
CVarClear("gLetItSnow");
}
srand(now);
#ifdef ENABLE_CROWD_CONTROL
CrowdControl::Instance = new CrowdControl();
CrowdControl::Instance->Init();

View File

@ -146,7 +146,7 @@ void EntranceTracker_SetLastEntranceOverride(s16 entranceIndex);
void Gfx_RegisterBlendedTexture(const char* name, u8* mask, u8* replacement);
void SaveManager_ThreadPoolWait();
uint32_t GetGIID(uint32_t itemID);
int32_t GetGIID(uint32_t itemID);
#endif
#endif

View File

@ -756,14 +756,18 @@ void SaveManager::SaveFileThreaded(int fileNum, SaveContext* saveContext) {
GameInteractor::Instance->ExecuteHooks<GameInteractor::OnSaveFile>(fileNum);
}
void SaveManager::SaveFile(int fileNum) {
void SaveManager::SaveFile(int fileNum, bool threaded) {
if (fileNum == 0xFF) {
return;
}
// Can't think of any time the promise would be needed, so use push_task instead of submit
auto saveContext = new SaveContext;
memcpy(saveContext, &gSaveContext, sizeof(gSaveContext));
if (threaded) {
smThreadPool->push_task_back(&SaveManager::SaveFileThreaded, this, fileNum, saveContext);
} else {
SaveFileThreaded(fileNum, saveContext);
}
}
void SaveManager::SaveGlobal() {
@ -2143,7 +2147,7 @@ void SaveManager::ConvertFromUnversioned() {
static SaveContext saveContextSave = gSaveContext;
InitFile(false);
CopyV0Save(*file, gSaveContext);
SaveFile(fileNum);
SaveFile(fileNum, false);
InitMeta(fileNum);
gSaveContext = saveContextSave;
}
@ -2164,7 +2168,7 @@ extern "C" void Save_InitFile(int isDebug) {
}
extern "C" void Save_SaveFile(void) {
SaveManager::Instance->SaveFile(gSaveContext.fileNum);
SaveManager::Instance->SaveFile(gSaveContext.fileNum, true);
}
extern "C" void Save_SaveGlobal(void) {

View File

@ -52,7 +52,7 @@ public:
void Init();
void InitFile(bool isDebug);
void SaveFile(int fileNum);
void SaveFile(int fileNum, bool threaded);
void SaveGlobal();
void LoadFile(int fileNum);
bool SaveFile_Exist(int fileNum);

View File

@ -15,6 +15,7 @@
#endif
#include "soh/Enhancements/game-interactor/GameInteractor.h"
#include "soh/Enhancements/game-interactor/GameInteractor_Hooks.h"
#define DO_ACTION_TEX_WIDTH() 48
@ -1706,7 +1707,12 @@ u8 Return_Item_Entry(GetItemEntry itemEntry, ItemID returnItem ) {
// Processes Item_Give returns
u8 Return_Item(u8 itemID, ModIndex modId, ItemID returnItem) {
uint32_t get = GetGIID(itemID);
// ITEM_SOLD_OUT doesn't have an ItemTable entry, so pass custom entry instead
if (itemID == ITEM_SOLD_OUT) {
GetItemEntry gie = { ITEM_SOLD_OUT, 0, 0, 0, 0, 0, 0, 0, false, ITEM_FROM_NPC, ITEM_CATEGORY_LESSER, NULL };
return Return_Item_Entry(gie, returnItem);
}
int32_t get = GetGIID(itemID);
if (get == -1) {
modId = MOD_RANDOMIZER;
get = itemID;
@ -6158,8 +6164,13 @@ void Interface_Update(PlayState* play) {
u16 tempSaleMod = gSaveContext.pendingSaleMod;
gSaveContext.pendingSale = ITEM_NONE;
gSaveContext.pendingSaleMod = MOD_NONE;
if (tempSaleMod == 0) {
tempSaleItem = GetGIID(tempSaleItem);
if (tempSaleMod == MOD_NONE) {
s16 giid = GetGIID(tempSaleItem);
if (giid == -1) {
tempSaleMod = MOD_RANDOMIZER;
} else {
tempSaleItem = giid;
}
}
GameInteractor_ExecuteOnSaleEndHooks(ItemTable_RetrieveEntry(tempSaleMod, tempSaleItem));
}

View File

@ -604,6 +604,15 @@ void Play_Init(GameState* thisx) {
(s32)(zAllocAligned + zAllocSize) - (s32)(zAllocAligned - zAlloc));
Fault_AddClient(&D_801614B8, ZeldaArena_Display, NULL, NULL);
// In order to keep bunny hood equipped on first load, we need to pre-set the age reqs for the item and slot
if (CVarGetInteger("gMMBunnyHood", 0) || CVarGetInteger("gTimelessEquipment", 0)) {
gItemAgeReqs[ITEM_MASK_BUNNY] = 9;
if(INV_CONTENT(ITEM_TRADE_CHILD) == ITEM_MASK_BUNNY)
gSlotAgeReqs[SLOT_TRADE_CHILD] = 9;
}
else {
gItemAgeReqs[ITEM_MASK_BUNNY] = gSlotAgeReqs[SLOT_TRADE_CHILD] = 1;
}
func_800304DC(play, &play->actorCtx, play->linkActorEntry);
while (!func_800973FC(play, &play->roomCtx)) {

View File

@ -109,7 +109,9 @@ void BgDyYoseizo_Init(Actor* thisx, PlayState* play2) {
this->actionFunc = BgDyYoseizo_CheckMagicAcquired;
}
void BgDyYoseizo_Destroy(Actor* this, PlayState* play) {
void BgDyYoseizo_Destroy(Actor* thisx, PlayState* play) {
BgDyYoseizo* this = (BgDyYoseizo*)thisx;
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
static Color_RGB8 sParticlePrimColors[] = {

View File

@ -346,6 +346,8 @@ void BossSst_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyJntSph(play, &this->colliderJntSph);
Collider_DestroyCylinder(play, &this->colliderCyl);
Audio_StopSfxByPos(&this->center);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void BossSst_HeadSetupLurk(BossSst* this) {

View File

@ -24,6 +24,9 @@ void DemoIk_Type1Draw(DemoIk* this, PlayState* play);
void DemoIk_Type2Draw(DemoIk* this, PlayState* play);
void DemoIk_Destroy(Actor* thisx, PlayState* play) {
DemoIk* this = (DemoIk*)thisx;
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void DemoIk_BgCheck(DemoIk* this, PlayState* play) {

View File

@ -1163,7 +1163,10 @@ void DemoIm_Init(Actor* thisx, PlayState* play) {
}
void DemoIm_Destroy(Actor* thisx, PlayState* play) {
DemoIm* this = (DemoIm*)thisx;
DemoIm_DestroyCollider(thisx, play);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 DemoIm_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {

View File

@ -203,6 +203,8 @@ void DoorKiller_Destroy(Actor* thisx, PlayState* play) {
if ((thisx->params & 0xFF) == DOOR_KILLER_DOOR) {
Collider_DestroyCylinder(play, &this->colliderCylinder);
Collider_DestroyJntSph(play, &this->colliderJntSph);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
}

View File

@ -97,7 +97,16 @@ void DoorWarp1_Destroy(Actor* thisx, PlayState* play) {
play->envCtx.adjAmbientColor[i] = play->envCtx.adjFogColor[i] = play->envCtx.adjLight1Color[i] =
0;
}
//! @bug SkelAnime_Free is not called for crystal variants
switch (this->actor.params) {
case WARP_DUNGEON_ADULT:
case WARP_BLUE_CRYSTAL:
case WARP_PURPLE_CRYSTAL:
SkelAnime_Free(&this->skelAnime, play);
break;
default:
break;
}
}
void DoorWarp1_SetupWarp(DoorWarp1* this, PlayState* play) {

View File

@ -249,6 +249,8 @@ void EnAm_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyCylinder(play, &this->hurtCollider);
Collider_DestroyCylinder(play, &this->blockCollider);
//! @bug Quad collider is not destroyed (though destroy doesnt really do anything anyway)
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnAm_SpawnEffects(EnAm* this, PlayState* play) {

View File

@ -95,6 +95,8 @@ void EnAni_Destroy(Actor* thisx, PlayState* play) {
EnAni* this = (EnAni*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 EnAni_SetText(EnAni* this, PlayState* play, u16 textId) {

View File

@ -167,6 +167,8 @@ void EnAnubice_Destroy(Actor* thisx, PlayState* play) {
tag->anubis = NULL;
}
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnAnubice_FindFlameCircles(EnAnubice* this, PlayState* play) {

View File

@ -68,6 +68,8 @@ void EnAttackNiw_Destroy(Actor* thisx, PlayState* play) {
cucco->unk_296--;
}
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_809B5268(EnAttackNiw* this, PlayState* play, s16 arg2) {

View File

@ -403,6 +403,8 @@ void EnBb_Destroy(Actor* thisx, PlayState* play) {
EnBb* this = (EnBb*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnBb_SetupFlameTrail(EnBb* this) {

View File

@ -196,6 +196,8 @@ void EnBigokuta_Destroy(Actor* thisx, PlayState* play) {
for (i = 0; i < ARRAY_COUNT(this->cylinder); i++) {
Collider_DestroyCylinder(play, &this->cylinder[i]);
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_809BCE3C(EnBigokuta* this) {

View File

@ -136,6 +136,8 @@ void EnBili_Destroy(Actor* thisx, PlayState* play) {
EnBili* this = (EnBili*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
// Setup Action Functions

View File

@ -62,6 +62,9 @@ void EnBird_Init(Actor* thisx, PlayState* play) {
}
void EnBird_Destroy(Actor* thisx, PlayState* play) {
EnBird* this = (EnBird*)thisx;
SkelAnime_Free(&this->skelAnime, play);
}
void func_809C1CAC(EnBird* this, s16 params) {

View File

@ -89,6 +89,9 @@ void EnBomBowlMan_Init(Actor* thisx, PlayState* play2) {
}
void EnBomBowlMan_Destroy(Actor* thisx, PlayState* play) {
EnBomBowlMan* this = (EnBomBowlMan*)thisx;
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnBomBowMan_SetupWaitAsleep(EnBomBowlMan* this, PlayState* play) {

View File

@ -208,6 +208,8 @@ void EnBox_Destroy(Actor* thisx, PlayState* play) {
EnBox* this = (EnBox*)thisx;
DynaPoly_DeleteBgActor(play, &play->colCtx.dyna, this->dyna.bgId);
ResourceMgr_UnregisterSkeleton(&this->skelanime);
}
void EnBox_RandomDustKinematic(EnBox* this, Vec3f* pos, Vec3f* velocity, Vec3f* accel) {

View File

@ -102,6 +102,8 @@ void EnBrob_Destroy(Actor* thisx, PlayState* play) {
DynaPoly_DeleteBgActor(play, &play->colCtx.dyna, this->dyna.bgId);
Collider_DestroyCylinder(play, &this->colliders[0]);
Collider_DestroyCylinder(play, &this->colliders[1]);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_809CADDC(EnBrob* this, PlayState* play) {

View File

@ -180,6 +180,8 @@ void EnButte_Destroy(Actor* thisx, PlayState* play2) {
EnButte* this = (EnButte*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_809CD56C(EnButte* this) {

View File

@ -161,6 +161,8 @@ void EnBw_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyCylinder(play, &this->collider1);
Collider_DestroyCylinder(play, &this->collider2);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_809CE884(EnBw* this, PlayState* play) {

View File

@ -162,6 +162,8 @@ void EnCow_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyCylinder(play, &this->colliders[0]);
Collider_DestroyCylinder(play, &this->colliders[1]);
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_809DF494(EnCow* this, PlayState* play) {

View File

@ -124,6 +124,8 @@ void EnCrow_Destroy(Actor* thisx, PlayState* play) {
EnCrow* this = (EnCrow*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
// Setup Action functions

View File

@ -161,6 +161,8 @@ void EnCs_Destroy(Actor* thisx, PlayState* play) {
EnCs* this = (EnCs*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 EnCs_GetTalkState(EnCs* this, PlayState* play) {

View File

@ -219,6 +219,8 @@ void EnDaiku_Destroy(Actor* thisx, PlayState* play) {
EnDaiku* this = (EnDaiku*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 EnDaiku_UpdateTalking(EnDaiku* this, PlayState* play) {

View File

@ -208,6 +208,8 @@ void EnDaikuKakariko_Destroy(Actor* thisx, PlayState* play) {
EnDaikuKakariko* this = (EnDaikuKakariko*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 EnDaikuKakariko_GetTalkState(EnDaikuKakariko* this, PlayState* play) {

View File

@ -278,6 +278,8 @@ void EnDekubaba_Destroy(Actor* thisx, PlayState* play) {
EnDekubaba* this = (EnDekubaba*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDekubaba_DisableHitboxes(EnDekubaba* this) {

View File

@ -136,6 +136,8 @@ void EnDekunuts_Destroy(Actor* thisx, PlayState* play) {
if (this->actor.params != DEKUNUTS_FLOWER) {
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
}

View File

@ -164,6 +164,8 @@ void EnDh_Destroy(Actor* thisx, PlayState* play) {
func_800F5B58();
Collider_DestroyCylinder(play, &this->collider1);
Collider_DestroyJntSph(play, &this->collider2);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDh_SpawnDebris(PlayState* play, EnDh* this, Vec3f* spawnPos, f32 spread, s32 arg4, f32 accelXZ,

View File

@ -177,6 +177,8 @@ void EnDha_Destroy(Actor* thisx, PlayState* play) {
EnDha* this = (EnDha*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDha_SetupWait(EnDha* this) {

View File

@ -108,6 +108,8 @@ void EnDivingGame_Destroy(Actor* thisx, PlayState* play) {
gSaveContext.timer1State = 0;
}
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDivingGame_SpawnRuppy(EnDivingGame* this, PlayState* play) {

View File

@ -200,6 +200,8 @@ void EnDns_Destroy(Actor* thisx, PlayState* play) {
EnDns* this = (EnDns*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDns_ChangeAnim(EnDns* this, u8 index) {

View File

@ -96,6 +96,8 @@ void EnDntJiji_Destroy(Actor* thisx, PlayState* play) {
EnDntJiji* this = (EnDntJiji*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDntJiji_SetFlower(EnDntJiji* this, PlayState* play) {

View File

@ -167,6 +167,8 @@ void EnDntNomal_Destroy(Actor* thisx, PlayState* play) {
} else {
Collider_DestroyCylinder(play, &this->bodyCyl);
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDntNomal_WaitForObject(EnDntNomal* this, PlayState* play) {

View File

@ -88,6 +88,8 @@ void EnDodojr_Destroy(Actor* thisx, PlayState* play) {
EnDodojr* this = (EnDodojr*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_809F64D0(EnDodojr* this) {

View File

@ -353,6 +353,8 @@ void EnDodongo_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyTris(play, &this->colliderHard);
Collider_DestroyJntSph(play, &this->colliderBody);
Collider_DestroyQuad(play, &this->colliderAT);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDodongo_SetupIdle(EnDodongo* this) {

View File

@ -300,6 +300,8 @@ void EnDog_Init(Actor* thisx, PlayState* play) {
void EnDog_Destroy(Actor* thisx, PlayState* play) {
EnDog* this = (EnDog*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDog_FollowPath(EnDog* this, PlayState* play) {

View File

@ -143,6 +143,8 @@ void EnDoor_Destroy(Actor* thisx, PlayState* play) {
if (transitionEntry->id < 0) {
transitionEntry->id = -transitionEntry->id;
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDoor_SetupType(EnDoor* this, PlayState* play) {

View File

@ -50,6 +50,9 @@ void EnDs_Init(Actor* thisx, PlayState* play) {
}
void EnDs_Destroy(Actor* thisx, PlayState* play) {
EnDs* this = (EnDs*)thisx;
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnDs_Talk(EnDs* this, PlayState* play) {

View File

@ -171,6 +171,8 @@ void EnEiyer_Init(Actor* thisx, PlayState* play) {
void EnEiyer_Destroy(Actor* thisx, PlayState* play) {
EnEiyer* this = (EnEiyer*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelanime);
}
void EnEiyer_RotateAroundHome(EnEiyer* this) {

View File

@ -437,6 +437,8 @@ void EnElf_Destroy(Actor* thisx, PlayState* play) {
LightContext_RemoveLight(play, &play->lightCtx, this->lightNodeGlow);
LightContext_RemoveLight(play, &play->lightCtx, this->lightNodeNoGlow);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_80A02A20(EnElf* this, PlayState* play) {

View File

@ -472,6 +472,8 @@ void EnFd_Destroy(Actor* thisx, PlayState* play) {
EnFd* this = (EnFd*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnFd_Reappear(EnFd* this, PlayState* play) {

View File

@ -198,6 +198,8 @@ void EnFirefly_Destroy(Actor* thisx, PlayState* play) {
EnFirefly* this = (EnFirefly*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnFirefly_SetupFlyIdle(EnFirefly* this) {

View File

@ -157,6 +157,8 @@ void EnFish_Destroy(Actor* thisx, PlayState* play2) {
EnFish* this = (EnFish*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnFish_SetYOffset(EnFish* this) {

View File

@ -179,6 +179,8 @@ void EnFloormas_Destroy(Actor* thisx, PlayState* play) {
EnFloormas* this = (EnFloormas*)thisx;
ColliderCylinder* col = &this->collider;
Collider_DestroyCylinder(play, col);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnFloormas_MakeInvulnerable(EnFloormas* this) {

View File

@ -309,6 +309,9 @@ void EnFr_Destroy(Actor* thisx, PlayState* play) {
EnFr* this = (EnFr*)thisx;
LightContext_RemoveLight(play, &play->lightCtx, this->lightNode);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
ResourceMgr_UnregisterSkeleton(&this->skelAnimeButterfly);
}
void EnFr_IsDivingIntoWater(EnFr* this, PlayState* play) {

View File

@ -99,6 +99,8 @@ void EnFu_Init(Actor* thisx, PlayState* play) {
void EnFu_Destroy(Actor* thisx, PlayState* play) {
EnFu* this = (EnFu*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelanime);
}
s32 func_80A1D94C(EnFu* this, PlayState* play, u16 textID, EnFuActionFunc actionFunc) {

View File

@ -208,6 +208,8 @@ void EnFw_Init(Actor* thisx, PlayState* play) {
void EnFw_Destroy(Actor* thisx, PlayState* play) {
EnFw* this = (EnFw*)thisx;
Collider_DestroyJntSph(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnFw_Bounce(EnFw* this, PlayState* play) {

View File

@ -224,6 +224,8 @@ void EnGb_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyCylinder(play, &this->collider);
LightContext_RemoveLight(play, &play->lightCtx, this->light);
DynaPoly_DeleteBgActor(play, &play->colCtx.dyna, this->dyna.bgId);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_80A2F608(EnGb* this) {

View File

@ -203,6 +203,8 @@ void EnGe1_Destroy(Actor* thisx, PlayState* play) {
EnGe1* this = (EnGe1*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 EnGe1_SetTalkAction(EnGe1* this, PlayState* play, u16 textId, f32 arg3, EnGe1ActionFunc actionFunc) {

View File

@ -174,6 +174,8 @@ void EnGe2_Destroy(Actor* thisx, PlayState* play) {
EnGe2* this = (EnGe2*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
// Detection/check functions

View File

@ -90,6 +90,8 @@ void EnGe3_Destroy(Actor* thisx, PlayState* play) {
EnGe3* this = (EnGe3*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnGe3_TurnToFacePlayer(EnGe3* this, PlayState* play) {

View File

@ -269,6 +269,8 @@ void EnGeldB_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyTris(play, &this->blockCollider);
Collider_DestroyCylinder(play, &this->bodyCollider);
Collider_DestroyQuad(play, &this->swordCollider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 EnGeldB_ReactToPlayer(PlayState* play, EnGeldB* this, s16 arg2) {

View File

@ -452,11 +452,6 @@ void EnGirlA_Init(Actor* thisx, PlayState* play) {
}
void EnGirlA_Destroy(Actor* thisx, PlayState* play) {
EnGirlA* this = (EnGirlA*)thisx;
if (this->isInitialized) {
SkelAnime_Free(&this->skelAnime, play);
}
}
s32 EnGirlA_CanBuy_Arrows(PlayState* play, EnGirlA* this) {

View File

@ -88,6 +88,8 @@ void EnGm_Destroy(Actor* thisx, PlayState* play) {
EnGm* this = (EnGm*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 func_80A3D7C8(void) {

View File

@ -1691,6 +1691,9 @@ void EnGo2_Init(Actor* thisx, PlayState* play) {
}
void EnGo2_Destroy(Actor* thisx, PlayState* play) {
EnGo2* this = (EnGo2*)thisx;
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnGo2_CurledUp(EnGo2* this, PlayState* play) {

View File

@ -177,6 +177,8 @@ void EnGoma_Destroy(Actor* thisx, PlayState* play) {
if (this->actor.params < 10) {
Collider_DestroyCylinder(play, &this->colCyl1);
Collider_DestroyCylinder(play, &this->colCyl2);
ResourceMgr_UnregisterSkeleton(&this->skelanime);
}
}

View File

@ -71,6 +71,8 @@ void EnGuest_Destroy(Actor* thisx, PlayState* play) {
EnGuest* this = (EnGuest*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnGuest_Update(Actor* thisx, PlayState* play) {

View File

@ -142,6 +142,9 @@ void EnHeishi1_Init(Actor* thisx, PlayState* play) {
}
void EnHeishi1_Destroy(Actor* thisx, PlayState* play) {
EnHeishi1* this = (EnHeishi1*)thisx;
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnHeishi1_SetupWalk(EnHeishi1* this, PlayState* play) {

View File

@ -166,6 +166,8 @@ void EnHeishi2_Destroy(Actor* thisx, PlayState* play) {
if ((this->collider.dim.radius != 0) || (this->collider.dim.height != 0)) {
Collider_DestroyCylinder(play, &this->collider);
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnHeishi2_DoNothing1(EnHeishi2* this, PlayState* play) {

View File

@ -90,6 +90,8 @@ void EnHeishi3_Destroy(Actor* thisx, PlayState* play) {
EnHeishi3* this = (EnHeishi3*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnHeishi3_SetupGuardType(EnHeishi3* this, PlayState* play) {

View File

@ -107,6 +107,8 @@ void EnHeishi4_Destroy(Actor* thisx, PlayState* play) {
EnHeishi4* this = (EnHeishi4*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_80A56328(EnHeishi4* this, PlayState* play) {

View File

@ -105,6 +105,8 @@ void EnHintnuts_Destroy(Actor* thisx, PlayState* play) {
if (this->actor.params != 0xA) {
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
}

View File

@ -116,6 +116,8 @@ void EnHs_Destroy(Actor* thisx, PlayState* play) {
EnHs* this = (EnHs*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 func_80A6E53C(EnHs* this, PlayState* play, u16 textId, EnHsActionFunc actionFunc) {

View File

@ -71,6 +71,8 @@ void EnHs2_Destroy(Actor* thisx, PlayState* play) {
EnHs2* this = (EnHs2*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 func_80A6F0B4(EnHs2* this, PlayState* play, u16 textId, EnHs2ActionFunc actionFunc) {

View File

@ -906,6 +906,8 @@ void EnHy_Destroy(Actor* thisx, PlayState* play) {
EnHy* this = (EnHy*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnHy_InitImpl(EnHy* this, PlayState* play) {

View File

@ -175,6 +175,8 @@ void EnIk_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyTris(play, &this->shieldCollider);
Collider_DestroyCylinder(play, &this->bodyCollider);
Collider_DestroyQuad(play, &this->axeCollider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnIk_SetupAction(EnIk* this, EnIkActionFunc actionFunc) {

View File

@ -503,6 +503,8 @@ void EnIn_Destroy(Actor* thisx, PlayState* play) {
if (this->actionFunc != NULL && this->actionFunc != func_80A79FB0) {
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
}

View File

@ -234,6 +234,8 @@ void EnInsect_Destroy(Actor* thisx, PlayState* play) {
if ((temp_v0 == 2 || temp_v0 == 3) && D_80A7DEB8 > 0) {
D_80A7DEB8--;
}
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_80A7C3A0(EnInsect* this) {

View File

@ -143,6 +143,8 @@ void EnJj_Destroy(Actor* thisx, PlayState* play) {
case JABUJABU_MAIN:
DynaPoly_DeleteBgActor(play, &play->colCtx.dyna, this->dyna.bgId);
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
break;
case JABUJABU_COLLISION:

View File

@ -76,6 +76,8 @@ void EnJs_Destroy(Actor* thisx, PlayState* play) {
EnJs* this = (EnJs*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
u8 func_80A88F64(EnJs* this, PlayState* play, u16 textId) {

View File

@ -59,8 +59,7 @@ void EnKakasi_Destroy(Actor* thisx, PlayState* play) {
EnKakasi* this = (EnKakasi*)thisx;
Collider_DestroyCylinder(play, &this->collider);
SkelAnime_Free(&this->skelanime, play); // OTR - Fixed this memory leak
//! @bug SkelAnime_Free is not called
SkelAnime_Free(&this->skelanime, play);
}
void EnKakasi_Init(Actor* thisx, PlayState* play) {

View File

@ -109,8 +109,7 @@ void EnKakasi2_Destroy(Actor* thisx, PlayState* play) {
EnKakasi2* this = (EnKakasi2*)thisx;
Collider_DestroyCylinder(play, &this->collider);
SkelAnime_Free(&this->skelAnime, play); // OTR - Fixed this memory leak
//! @bug SkelAnime_Free is not called
SkelAnime_Free(&this->skelAnime, play);
}
void func_80A90264(EnKakasi2* this, PlayState* play) {

View File

@ -63,8 +63,7 @@ void EnKakasi3_Destroy(Actor* thisx, PlayState* play) {
EnKakasi3* this = (EnKakasi3*)thisx;
Collider_DestroyCylinder(play, &this->collider);
SkelAnime_Free(&this->skelAnime, play); //OTR - Fixed this memory leak
//! @bug SkelAnime_Free is not called
SkelAnime_Free(&this->skelAnime, play);
}
void EnKakasi3_Init(Actor* thisx, PlayState* play) {

View File

@ -119,6 +119,8 @@ void EnKarebaba_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyCylinder(play, &this->bodyCollider);
Collider_DestroyCylinder(play, &this->headCollider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnKarebaba_ResetCollider(EnKarebaba* this) {

View File

@ -1145,6 +1145,8 @@ void EnKo_Init(Actor* thisx, PlayState* play) {
void EnKo_Destroy(Actor* thisx, PlayState* play) {
EnKo* this = (EnKo*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_80A99048(EnKo* this, PlayState* play) {

View File

@ -385,6 +385,8 @@ void EnKz_Destroy(Actor* thisx, PlayState* play) {
EnKz* this = (EnKz*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelanime);
}
void EnKz_PreMweepWait(EnKz* this, PlayState* play) {

View File

@ -336,6 +336,8 @@ void EnMb_Destroy(Actor* thisx, PlayState* play) {
Collider_DestroyTris(play, &this->frontShielding);
Collider_DestroyCylinder(play, &this->hitbox);
Collider_DestroyQuad(play, &this->attackCollider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void EnMb_FaceWaypoint(EnMb* this, PlayState* play) {

View File

@ -699,6 +699,8 @@ void EnMd_Init(Actor* thisx, PlayState* play) {
void EnMd_Destroy(Actor* thisx, PlayState* play) {
EnMd* this = (EnMd*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_80AAB874(EnMd* this, PlayState* play) {

View File

@ -79,6 +79,8 @@ void EnMk_Destroy(Actor* thisx, PlayState* play) {
EnMk* this = (EnMk*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
void func_80AACA40(EnMk* this, PlayState* play) {

View File

@ -198,6 +198,8 @@ void EnMm_Destroy(Actor* thisx, PlayState* play) {
EnMm* this = (EnMm*)thisx;
Collider_DestroyCylinder(play, &this->collider);
ResourceMgr_UnregisterSkeleton(&this->skelAnime);
}
s32 func_80AADA70(void) {

Some files were not shown because too many files have changed in this diff Show More