From 603403025b41f85ef85799654fded08939961a68 Mon Sep 17 00:00:00 2001 From: louist103 <35883445+louist103@users.noreply.github.com> Date: Sun, 30 Mar 2025 18:34:53 -0400 Subject: [PATCH] Bump ZAPDTR & OTRExporter. Changes to use o2r by default Changes to the new player animation format # Conflicts: # OTRExporter # ZAPDTR # soh/soh/OTRGlobals.cpp # soh/src/code/z_skelanime.c --- .gitignore | 1 + CMakeLists.txt | 16 ++++---- OTRExporter | 2 +- ZAPDTR | 2 +- copy-existing-otrs.cmake | 40 +++++++++---------- soh/CMakeLists.txt | 4 +- soh/soh/Extractor/Extract.cpp | 2 +- soh/soh/OTRGlobals.cpp | 39 +++++++++--------- .../resource/importer/AnimationFactory.cpp | 7 +++- soh/src/code/z_skelanime.c | 36 +++++++---------- 10 files changed, 75 insertions(+), 74 deletions(-) diff --git a/.gitignore b/.gitignore index ac767f114..3aa34d9c5 100644 --- a/.gitignore +++ b/.gitignore @@ -412,6 +412,7 @@ ReleaseObj/* .tags tags *.otr +*.o2r *.sav shipofharkinian.ini shipofharkinian.json diff --git a/CMakeLists.txt b/CMakeLists.txt index 9c3945459..6c919ec3e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -174,7 +174,7 @@ set_property(TARGET soh PROPERTY APPIMAGE_ICON_FILE "${CMAKE_BINARY_DIR}/sohIcon if("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux") install(PROGRAMS "${CMAKE_BINARY_DIR}/linux/soh.sh" DESTINATION . COMPONENT appimage) -install(FILES "${CMAKE_BINARY_DIR}/soh/soh.otr" DESTINATION . COMPONENT ship) +install(FILES "${CMAKE_BINARY_DIR}/soh/soh.o2r" DESTINATION . COMPONENT ship) install(TARGETS ZAPD DESTINATION ./assets/extractor COMPONENT extractor) install(DIRECTORY "${CMAKE_SOURCE_DIR}/soh/assets/extractor/" DESTINATION ./assets/extractor COMPONENT extractor) install(DIRECTORY "${CMAKE_SOURCE_DIR}/soh/assets/xml/" DESTINATION ./assets/extractor/xmls COMPONENT extractor) @@ -198,18 +198,18 @@ find_package(Python3 COMPONENTS Interpreter) # Target to generate OTRs add_custom_target( ExtractAssets - COMMAND ${CMAKE_COMMAND} -E rm -f oot.otr oot-mq.otr soh.otr + COMMAND ${CMAKE_COMMAND} -E rm -f oot.o2r oot-mq.o2r soh.o2r # copy LUS default shaders into assets/custom COMMAND ${CMAKE_COMMAND} -E rm -r -f ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom/shaders/ COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/libultraship/src/graphic/Fast3D/shaders/ ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom/shaders/ - COMMAND ${Python3_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/OTRExporter/extract_assets.py -z "$" --non-interactive --xml-root ../soh/assets/xml --custom-otr-file soh.otr "--custom-assets-path" ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom --port-ver "${CMAKE_PROJECT_VERSION}" + COMMAND ${Python3_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/OTRExporter/extract_assets.py -z "$" --non-interactive --xml-root ../soh/assets/xml --custom-otr-file soh.o2r "--custom-assets-path" ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom --port-ver "${CMAKE_PROJECT_VERSION}" COMMAND ${CMAKE_COMMAND} -DSYSTEM_NAME=${CMAKE_SYSTEM_NAME} -DTARGET_DIR="$" -DSOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR} -DBINARY_DIR=${CMAKE_BINARY_DIR} -P ${CMAKE_CURRENT_SOURCE_DIR}/copy-existing-otrs.cmake WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/OTRExporter COMMENT "Running asset extraction..." DEPENDS ZAPD - BYPRODUCTS oot.otr ${CMAKE_SOURCE_DIR}/oot.otr oot-mq.otr ${CMAKE_SOURCE_DIR}/oot-mq.otr ${CMAKE_SOURCE_DIR}/soh.otr + BYPRODUCTS oot.o2r ${CMAKE_SOURCE_DIR}/oot.o2r oot-mq.o2r ${CMAKE_SOURCE_DIR}/oot-mq.o2r ${CMAKE_SOURCE_DIR}/soh.o2r ) # Target to generate headers @@ -221,19 +221,19 @@ add_custom_target( DEPENDS ZAPD ) -# Target to generate only soh.otr +# Target to generate only soh.o2r add_custom_target( GenerateSohOtr - COMMAND ${CMAKE_COMMAND} -E rm -f soh.otr + COMMAND ${CMAKE_COMMAND} -E rm -f soh.o2r # copy LUS default shaders into assets/custom COMMAND ${CMAKE_COMMAND} -E rm -r -f ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom/shaders/ COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/libultraship/src/graphic/Fast3D/shaders/ ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom/shaders/ - COMMAND ${Python3_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/OTRExporter/extract_assets.py -z "$" --norom --custom-otr-file soh.otr "--custom-assets-path" ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom --port-ver "${CMAKE_PROJECT_VERSION}" + COMMAND ${Python3_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/OTRExporter/extract_assets.py -z "$" --norom --custom-otr-file soh.o2r "--custom-assets-path" ${CMAKE_CURRENT_SOURCE_DIR}/soh/assets/custom --port-ver "${CMAKE_PROJECT_VERSION}" COMMAND ${CMAKE_COMMAND} -DSYSTEM_NAME=${CMAKE_SYSTEM_NAME} -DTARGET_DIR="$" -DSOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR} -DBINARY_DIR=${CMAKE_BINARY_DIR} -DONLYSOHOTR=On -P ${CMAKE_CURRENT_SOURCE_DIR}/copy-existing-otrs.cmake WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/OTRExporter - COMMENT "Generating soh.otr..." + COMMENT "Generating soh.o2r..." DEPENDS ZAPD ) diff --git a/OTRExporter b/OTRExporter index 41052efcd..35dbf63b4 160000 --- a/OTRExporter +++ b/OTRExporter @@ -1 +1 @@ -Subproject commit 41052efcdf8df8e67517cc93da8975fcd4e14af9 +Subproject commit 35dbf63b4e70a21744ce6ecf9dff7db266b4f2d5 diff --git a/ZAPDTR b/ZAPDTR index 2aeababbf..c3ee03cfe 160000 --- a/ZAPDTR +++ b/ZAPDTR @@ -1 +1 @@ -Subproject commit 2aeababbfb81b00d34673406453e8e8e2deaa27b +Subproject commit c3ee03cfe3072fc01df256d365115a1f3ccaf012 diff --git a/copy-existing-otrs.cmake b/copy-existing-otrs.cmake index f5226510c..5fe1eafd3 100644 --- a/copy-existing-otrs.cmake +++ b/copy-existing-otrs.cmake @@ -1,37 +1,37 @@ message(STATUS "Copying otr files...") -if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot.otr) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot.otr ${SOURCE_DIR}) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot.otr ${BINARY_DIR}/soh/) - message(STATUS "Copied oot.otr") +if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot.o2r) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot.o2r ${SOURCE_DIR}) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot.o2r ${BINARY_DIR}/soh/) + message(STATUS "Copied oot.o2r") endif() -if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot-mq.otr) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot-mq.otr ${SOURCE_DIR}) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot-mq.otr ${BINARY_DIR}/soh/) - message(STATUS "Copied oot-mq.otr") +if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot-mq.o2r) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot-mq.o2r ${SOURCE_DIR}) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot-mq.o2r ${BINARY_DIR}/soh/) + message(STATUS "Copied oot-mq.o2r") endif() -if(EXISTS ${SOURCE_DIR}/OTRExporter/soh.otr) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy soh.otr ${SOURCE_DIR}) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy soh.otr ${BINARY_DIR}/soh/) - message(STATUS "Copied soh.otr") +if(EXISTS ${SOURCE_DIR}/OTRExporter/soh.o2r) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy soh.o2r ${SOURCE_DIR}) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy soh.o2r ${BINARY_DIR}/soh/) + message(STATUS "Copied soh.o2r") endif() # Additionally for Windows, copy the otrs to the target dir, side by side with soh.exe if(SYSTEM_NAME MATCHES "Windows") - if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot.otr) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot.otr ${TARGET_DIR}) + if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot.o2r) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot.o2r ${TARGET_DIR}) endif() - if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot-mq.otr) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot-mq.otr ${TARGET_DIR}) + if(NOT ONLYSOHOTR AND EXISTS ${SOURCE_DIR}/OTRExporter/oot-mq.o2r) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy oot-mq.o2r ${TARGET_DIR}) endif() - if(EXISTS ${SOURCE_DIR}/OTRExporter/soh.otr) - execute_process(COMMAND ${CMAKE_COMMAND} -E copy soh.otr ${TARGET_DIR}) + if(EXISTS ${SOURCE_DIR}/OTRExporter/soh.o2r) + execute_process(COMMAND ${CMAKE_COMMAND} -E copy soh.o2r ${TARGET_DIR}) endif() endif() -if(NOT ONLYSOHOTR AND (NOT EXISTS ${SOURCE_DIR}/oot.otr AND NOT EXISTS ${SOURCE_DIR}/oot-mq.otr)) +if(NOT ONLYSOHOTR AND (NOT EXISTS ${SOURCE_DIR}/oot.o2r AND NOT EXISTS ${SOURCE_DIR}/oot-mq.o2r)) message(FATAL_ERROR "Failed to copy. No OTR files found.") endif() -if(NOT EXISTS ${SOURCE_DIR}/soh.otr) +if(NOT EXISTS ${SOURCE_DIR}/soh.o2r) message(FATAL_ERROR "Failed to copy. No soh OTR found.") endif() diff --git a/soh/CMakeLists.txt b/soh/CMakeLists.txt index 7277b2dfb..909113ee9 100644 --- a/soh/CMakeLists.txt +++ b/soh/CMakeLists.txt @@ -709,7 +709,7 @@ endif() if (CMAKE_SYSTEM_NAME STREQUAL "Windows") INSTALL(FILES $ DESTINATION ./debug COMPONENT ship) -INSTALL(FILES ${CMAKE_BINARY_DIR}/soh/soh.otr DESTINATION . COMPONENT ship) +INSTALL(FILES ${CMAKE_BINARY_DIR}/soh/soh.o2r DESTINATION . COMPONENT ship) endif() if(CMAKE_SYSTEM_NAME STREQUAL "Linux") @@ -723,7 +723,7 @@ if("${CMAKE_SYSTEM_NAME}" STREQUAL "Darwin") configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/macosx/Info.plist.in ${CMAKE_BINARY_DIR}/macosx/Info.plist @ONLY) INSTALL(TARGETS soh DESTINATION ../MacOS COMPONENT ship) INSTALL(FILES ${CMAKE_BINARY_DIR}/gamecontrollerdb.txt DESTINATION ../MacOS COMPONENT ship) -INSTALL(FILES ${CMAKE_BINARY_DIR}/soh/soh.otr DESTINATION ../Resources COMPONENT ship) +INSTALL(FILES ${CMAKE_BINARY_DIR}/soh/soh.o2r DESTINATION ../Resources COMPONENT ship) elseif(NOT "${CMAKE_SYSTEM_NAME}" MATCHES "NintendoSwitch|CafeOS") INSTALL(FILES ${CMAKE_BINARY_DIR}/gamecontrollerdb.txt DESTINATION . COMPONENT ship) endif() diff --git a/soh/soh/Extractor/Extract.cpp b/soh/soh/Extractor/Extract.cpp index 43f86a285..340f1697b 100644 --- a/soh/soh/Extractor/Extract.cpp +++ b/soh/soh/Extractor/Extract.cpp @@ -615,7 +615,7 @@ bool Extractor::CallZapd(std::string installPath, std::string exportdir) { char portVersion[18]; // 5 digits for int16_max (x3) + separators + terminator std::array argv; const char* version = GetZapdVerStr(); - const char* otrFile = IsMasterQuest() ? "oot-mq.otr" : "oot.otr"; + const char* otrFile = IsMasterQuest() ? "oot-mq.o2r" : "oot.o2r"; std::string romPath = std::filesystem::absolute(mCurrentRomPath).string(); installPath = std::filesystem::absolute(installPath).string(); diff --git a/soh/soh/OTRGlobals.cpp b/soh/soh/OTRGlobals.cpp index 0151773a9..835b4b0bc 100644 --- a/soh/soh/OTRGlobals.cpp +++ b/soh/soh/OTRGlobals.cpp @@ -263,15 +263,15 @@ const char* constCameraStrings[] = { OTRGlobals::OTRGlobals() { std::vector OTRFiles; - std::string mqPath = Ship::Context::LocateFileAcrossAppDirs("oot-mq.otr", appShortName); + std::string mqPath = Ship::Context::LocateFileAcrossAppDirs("oot-mq.o2r", appShortName); if (std::filesystem::exists(mqPath)) { OTRFiles.push_back(mqPath); } - std::string ootPath = Ship::Context::LocateFileAcrossAppDirs("oot.otr", appShortName); + std::string ootPath = Ship::Context::LocateFileAcrossAppDirs("oot.o2r", appShortName); if (std::filesystem::exists(ootPath)) { OTRFiles.push_back(ootPath); } - std::string sohOtrPath = Ship::Context::GetPathRelativeToAppBundle("soh.otr"); + std::string sohOtrPath = Ship::Context::GetPathRelativeToAppBundle("soh.o2r"); if (std::filesystem::exists(sohOtrPath)) { OTRFiles.push_back(sohOtrPath); } @@ -945,7 +945,7 @@ OTRVersion ReadPortVersionFromOTR(std::string otrPath) { OTRVersion version = {}; // Use a temporary archive instance to load the otr and read the version file - auto archive = std::make_shared(otrPath); + auto archive = std::make_shared(otrPath); if (archive->Open()) { auto t = archive->LoadFile("portVersion"); if (t != nullptr && t->IsLoaded) { @@ -963,7 +963,7 @@ OTRVersion ReadPortVersionFromOTR(std::string otrPath) { return version; } -// Check that a soh.otr exists and matches the version of soh running +// Check that a soh.o2r exists and matches the version of soh running // Otherwise show a message and exit void CheckSoHOTRVersion(std::string otrPath) { std::string msg; @@ -972,20 +972,20 @@ void CheckSoHOTRVersion(std::string otrPath) { msg = "\x1b[4;2HPlease re-extract it from the download." "\x1b[6;2HPress the Home button to exit..."; #elif defined(__WIIU__) - msg = "Please extract the soh.otr from the Ship of Harkinian download\nto your folder.\n\nPress and hold the power " + msg = "Please extract the soh.o2r from the Ship of Harkinian download\nto your folder.\n\nPress and hold the power " "button to shutdown..."; #else - msg = "Please extract the soh.otr from the Ship of Harkinian download to your folder.\n\nExiting..."; + msg = "Please extract the soh.o2r from the Ship of Harkinian download to your folder.\n\nExiting..."; #endif if (!std::filesystem::exists(otrPath)) { #if not defined(__SWITCH__) && not defined(__WIIU__) - Extractor::ShowErrorBox("soh.otr file is missing", msg.c_str()); + Extractor::ShowErrorBox("soh.o2r file is missing", msg.c_str()); exit(1); #elif defined(__SWITCH__) - Ship::Switch::PrintErrorMessageToScreen(("\x1b[2;2HYou are missing the soh.otr file." + msg).c_str()); + Ship::Switch::PrintErrorMessageToScreen(("\x1b[2;2HYou are missing the soh.o2r file." + msg).c_str()); #elif defined(__WIIU__) - OSFatal(("You are missing the soh.otr file\n\n" + msg).c_str()); + OSFatal(("You are missing the soh.o2r file\n\n" + msg).c_str()); #endif } @@ -994,12 +994,12 @@ void CheckSoHOTRVersion(std::string otrPath) { if (otrVersion.major != gBuildVersionMajor || otrVersion.minor != gBuildVersionMinor || otrVersion.patch != gBuildVersionPatch) { #if not defined(__SWITCH__) && not defined(__WIIU__) - Extractor::ShowErrorBox("soh.otr file version does not match", msg.c_str()); + Extractor::ShowErrorBox("soh.o2r file version does not match", msg.c_str()); exit(1); #elif defined(__SWITCH__) - Ship::Switch::PrintErrorMessageToScreen(("\x1b[2;2HYou have an old soh.otr file." + msg).c_str()); + Ship::Switch::PrintErrorMessageToScreen(("\x1b[2;2HYou have an old soh.o2r file." + msg).c_str()); #elif defined(__WIIU__) - OSFatal(("You have an old soh.otr file\n\n" + msg).c_str()); + OSFatal(("You have an old soh.o2r file\n\n" + msg).c_str()); #endif } } @@ -1151,10 +1151,13 @@ extern "C" void InitOTR() { CheckAndCreateModFolder(); #endif - CheckSoHOTRVersion(Ship::Context::GetPathRelativeToAppBundle("soh.otr")); + CheckSoHOTRVersion(Ship::Context::GetPathRelativeToAppBundle("soh.o2r")); + const bool ootO2RExists = std::filesystem::exists(Ship::Context::LocateFileAcrossAppDirs("oot-mq.o2r", appShortName)) || + std::filesystem::exists(Ship::Context::LocateFileAcrossAppDirs("oot.o2r", appShortName)); + const bool ootOTRExists = std::filesystem::exists(Ship::Context::LocateFileAcrossAppDirs("oot-mq.otr", appShortName)) || + std::filesystem::exists(Ship::Context::LocateFileAcrossAppDirs("oot.otr", appShortName)); - if (!std::filesystem::exists(Ship::Context::LocateFileAcrossAppDirs("oot-mq.otr", appShortName)) && - !std::filesystem::exists(Ship::Context::LocateFileAcrossAppDirs("oot.otr", appShortName))) { + if (!ootOTRExists && !ootO2RExists) { #if not defined(__SWITCH__) && not defined(__WIIU__) std::string installPath = Ship::Context::GetAppBundlePath(); @@ -1200,8 +1203,8 @@ extern "C" void InitOTR() { #endif } - DetectOTRVersion("oot.otr", false); - DetectOTRVersion("oot-mq.otr", true); + DetectOTRVersion("oot.o2r", false); + DetectOTRVersion("oot-mq.o2r", true); OTRGlobals::Instance = new OTRGlobals(); CustomMessageManager::Instance = new CustomMessageManager(); diff --git a/soh/soh/resource/importer/AnimationFactory.cpp b/soh/soh/resource/importer/AnimationFactory.cpp index a3a36b5e8..a07537f07 100644 --- a/soh/soh/resource/importer/AnimationFactory.cpp +++ b/soh/soh/resource/importer/AnimationFactory.cpp @@ -1,6 +1,7 @@ #include "soh/resource/importer/AnimationFactory.h" #include "soh/resource/type/Animation.h" #include "spdlog/spdlog.h" +#include "Context.h" namespace SOH { std::shared_ptr @@ -80,7 +81,11 @@ ResourceFactoryBinaryAnimationV0::ReadResource(std::shared_ptr file, animation->animationData.linkAnimationHeader.common.frameCount = reader->ReadInt16(); // Read the segment pointer (always 32 bit, doesn't adjust for system pointer size) - animation->animationData.linkAnimationHeader.segment = (void*)reader->ReadUInt32(); + std::string path = reader->ReadString(); + const auto animData = std::static_pointer_cast( + Ship::Context::GetInstance()->GetResourceManager()->LoadResourceProcess(path.c_str())); + + animation->animationData.linkAnimationHeader.segment = animData->GetPointer(); } else if (animType == AnimationType::Legacy) { SPDLOG_DEBUG("BEYTAH ANIMATION?!"); } diff --git a/soh/src/code/z_skelanime.c b/soh/src/code/z_skelanime.c index 0773eb4e0..19e6fbcba 100644 --- a/soh/src/code/z_skelanime.c +++ b/soh/src/code/z_skelanime.c @@ -899,33 +899,25 @@ void AnimationContext_SetLoadFrame(PlayState* play, LinkAnimationHeader* animati if (ResourceMgr_OTRSigCheck(animation) != 0) animation = ResourceMgr_LoadAnimByName(animation); - LinkAnimationHeader* linkAnimHeader = SEGMENTED_TO_VIRTUAL(animation); + LinkAnimationHeader* playerAnimHeader = animation; Vec3s* ram = frameTable; - osCreateMesgQueue(&entry->data.load.msgQueue, &entry->data.load.msg, 1); - - char animPath[2048]; - - snprintf(animPath, sizeof(animPath), "misc/link_animetion/gPlayerAnimData_%06X", - (((uintptr_t)linkAnimHeader->segment - 0x07000000))); - + // osCreateMesgQueue(&entry->data.load.msgQueue, &entry->data.load.msg, 1); + // + // char animPath[2048]; + // + // snprintf(animPath, sizeof(animPath), "misc/link_animetion/gPlayerAnimData_%06X", + // (((uintptr_t)linkAnimHeader->segmentVoid - 0x07000000))); + // // printf("Streaming %s, seg = %08X\n", animPath, linkAnimHeader->segment); - s16* animData = ResourceMgr_LoadPlayerAnimByName(animPath); - + s16* animData = /* ResourceMgr_LoadPlayerAnimByName*/ (animation->segment); + // 2S2H [Port] sometimes a HESS can set a negative frame value from a negative playback speed. When converted to + // a signed value this will cause a crash due to copying way much data. + if (frame < 0) { + frame = 0; + } memcpy(ram, (uintptr_t)animData + (((sizeof(Vec3s) * limbCount + 2) * frame)), sizeof(Vec3s) * limbCount + 2); - - /*u32* ramPtr = (u32*)ram; - - for (int i = 0; i < 1024; i++) - { - ramPtr[i] = i * 7; - }*/ - - // DmaMgr_SendRequest2(&entry->data.load.req, ram, - // LINK_ANIMATION_OFFSET(linkAnimHeader->segment, ((sizeof(Vec3s) * limbCount + 2) * frame)), - // sizeof(Vec3s) * limbCount + 2, 0, &entry->data.load.msgQueue, NULL, __FILE__, - //__LINE__); } }