summaryrefslogtreecommitdiff
path: root/src/KingSystem
AgeCommit message (Collapse)Author
2026-10-15ksys/util: bind tryCreateDualHeap to the function bodyLéo Lam
The 8-byte function only masks the bool argument and branches to the body right after it, so the body is tryCreateDualHeap and the wrapper is createDualHeap (name from the IDB). GameData calls the wrapper, so it now calls createDualHeap. (AI assisted using Claude Opus 5.5)
2026-10-16ksys/phys: move motionTypeFromText to physUtilLéo Lam
motionTypeFromText isn't part of physDefines: its "Keyframed" string (only used there) sits between the StaticCompound and PlayReport strings in .rodata, far from physDefines' enum text, and the function is linked right after the contact listener's inline virtuals, so it most likely starts a new TU at 0x7100fd069c. Nothing separates it from getMaterialMaskFromShape and the other helpers in physUtil, so it goes in the same file and its declaration moves to physUtil.h. That part is a guess: neither function has data that would show a boundary. (AI assisted using Claude Opus 5.5)
2026-10-16ksys/phys: rename physStaticCompoundUtil to physUtilLéo Lam
Most of these helpers have nothing to do with StaticCompound: they look up material masks and collision filter info from shapes and collidables. physUtil also fits the link order, between physUserTag and physWorld, and it's what the function groups already call this block. (AI assisted using Claude Opus 5.5)
2026-10-15ksys/act: make calcHash a free function in actAwarenessMiscUtilsLéo Lam
calcHash is linked between AwarenessInstance's sinit and the next one, together with two AwarenessSourcePool helpers and the job queue functions of Awareness::Unk1, so it's a shared helper rather than an Awareness member, declared in the new file's own header. actAwareness.cpp calls this 4-byte function out of line, so it's likely not defined there. The file name sorts between actAwarenessInstance and the sensor files, which is where it is linked. (AI assisted using Claude Opus 5.5)
2026-10-15ksys, uking: move four definitions to match link orderLéo Lam
calc_ goes before leave_ in ForceSetCameraPos and InWaterSelForkASPlay, and RailRoute's dtor goes after getCheckPointName (an unnamed row there is likely its D0). BaseProcJobHandler's ctor is linked right before BaseProc's ctor, so it moves into actBaseProc.cpp, and the class moves into actBaseProc.h so that its declaration stays with its definition. (AI assisted using Claude Opus 5.5)
2026-10-15Name placeholder virtuals from their overridesLéo Lam
Each base class virtual is named after what its overrides do and how callers use it, e.g. AttCheck::calcMtx (0x710108a614) is the virtual that AttClient calls before testing its checks. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-13ksys: move AS setting, RootAi and three others to match link orderLéo Lam
Each file moves to where its code is linked, and namespaces follow the new paths. ASSettingMgr is an unofficial name. | Old | New | |---|---| | act::ASSetting (ActorSystem/actASSetting) | res::ASSettingMgr (Resource/Actor/resResourceASSettingMgr) | | Resource/resResourceASSetting, Resource/Actor/resResourceASResourceExtension | Resource/Actor/resResourceASSetting | | ksys::DebugFinder (System/DebugFinder) | ksys::act::DebugFinder (ActorSystem/actDebugFinder) | | ActorSystem/LOD/actLodState | ActorSystem/actLodState | | ActorSystem/actAiRoot | ActorSystem/aiRootAi | | Map/mapStagePreActorCache | System/StagePreActorCache (ksys) | (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-13ksys/phys: rearrange the folder layout to match link orderLéo Lam
A folder's files are linked before its subfolders, and the rigid body files are linked as one flat sequence. ListShape is the one file that does not fit this order. | Old | New | |---|---| | RigidBody/Shape/<Kind>/phys<Kind>Shape.cpp | RigidBody/Shape/phys<Kind>Shape.cpp | | RigidBody/Shape/<Kind>/phys<Kind>RigidBody.cpp | RigidBody/physRigidBody<Kind>.cpp | | RigidBody/Shape/List/physListShapeRigidBody.cpp | RigidBody/physRigidBodyListShape.cpp | | physHavokMemoryAllocator.cpp | System/physHavokMemoryAllocator.cpp | | StaticCompound/physStaticCompound{,Mgr,RigidBodyGroup,Util}.cpp | System/ | | StaticCompound/physStaticCompound{Info,Autogen}.cpp | System/physStaticCompoundInfo.cpp | The original has the type infos' cleanup functions just before StaticCompoundInfo's functions, so the merged file defines the reflection data first, with plain static cleanup functions as in Havok's generated reflection code. Template instantiations would be emitted after the rest of the file. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-13Move code to the TUs that match link order and rename filesLéo Lam
Rename classes and files so that they sort where their code is linked, and move code that is linked inside another TU into that TU's file. | Old | New | TU start | |---|---|---| | ActorAreaInOutSendMessage | AreaInOutSendMessage | 0x710009fa64 | | AreaTagAction | AreaActionBase | 0x7100e21e64 | | sndResource.{h,cpp} | sndSound.{h,cpp} | | | Code | From | To | |---|---|---| | SoundMgr | sndMgr.h | sndSound.h | | PlayReport | PlayReportMgr.cpp | PlayReport.cpp | | PlayReport::addPlayTimes, addPosition | PlayReportMgr.cpp | ProductReporter.cpp | (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-11ksys/act: split IDamageManager out of DamageManagerBaseLéo Lam
DamageManagerBase's root base class (previously DamageManagerBase_UnknownBase1) holds the damage callback list, and its code is linked among the ActorSystem objects rather than with the Game/Actor/Damage files. It appears to be an engine-side abstract base, so let's move it to KingSystem/ActorSystem as ksys::act::IDamageManager (unofficial name, following the ksys IManager/Manager pattern and Actor::getDamageMgr), together with DamageCallback and Struct20Base, and have Actor::getDamageMgr return it. DamageManagerBase now overrides its getters and inherits addDamageCallback/removeDamageCallback from it. The rest of the damage code stays in Game/Actor/Damage but is regrouped to match link order: Struct20::combineMaybe moves into actDamageManagerBase.cpp, Struct20::reset becomes inline and dmgStruct20.cpp becomes actDamageMgr.cpp. The uking::dmg namespace is merged into uking::act, so the files there take the act prefix too, and dmgInfoManager becomes actDamageInfoMgr after the class it holds. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-11Merge pull request #210 from Pistonight/lib/migrade_sdkLéo Lam
lib: botw migrate to new nnsdk repo
2026-10-10lib: migrate to new nnsdk repoPistonight
2026-10-11ksys/act: rename the actor accessor to ActorLinkConstDataAccessLéo Lam
The 0x18-sized accessor appears to be named ActorLinkConstDataAccess based on a source path string in the Wii U build. The 0x10-sized base class (which we had given the name to) only holds a BaseProc and its dtor/acquire functions live in a separate TU so let's rename it BaseProcAccessor (unofficial name). acquireActor is a header inline whose one copy landed in the BeamBase object. Nothing in BeamBase calls it, so the BeamBase function that used it was probably dead-stripped by the linker. (AI assisted using Claude Opus 5.5)
2026-10-06Actor: ActorFactory is game, CurrentResNameMgr is ksysLéo Lam
ActorFactory's static initialiser fills its table with uking actor ctors. CurrentResNameMgr (0x71010b770c) links in KingSystem/System right before GameConfig. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06The task and thread families are plain ksys::Léo Lam
They link in the same block as the plain-ksys:: Message family. getItemValue and applyScreenFade sit in engine UI TUs, hence ksys::ui. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06eft: move the effect actions to KingSystem/EffectLéo Lam
Link order: FootStepCalcOn (0x7100da1968) lies in the KingSystem/Effect block. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06ActorSystem: Fork AIs, DemoRootAI and queries are ksysLéo Lam
They form one run in the ActorSystem block (DemoRootAI at 0x7100d61e68, right after VillagerMgr). (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06SystemPauseMgr and NXArgs are game codeLéo Lam
Both link in the game archive, and NXArgs uses game classes such as GameScene. The engine only calls SystemPauseMgr's virtuals, so it now goes through ksys::ISystemPauseMgr and no longer includes Game/. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06aoc: Manager is ksys, the DLC managers stay game-sideLéo Lam
aoc::Manager is created during engine start-up and called by gdt, map and StarterPackMgr; only game code uses HardModeManager and ChampionBalladManager. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06AutoPlacement is game code: move it to Game/Léo Lam
It is created only from game code, no engine code calls it, and it hardcodes game actor names. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06ksys: small declaration fixesLéo Lam
setCamera's only caller passes the camera actor, a ksys::act::Actor; ksys::act::Camera is only forward-declared. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06Actor: PlayerInfo/PlayerBase are game, GameConfig ksysLéo Lam
Every decomp user of PlayerInfo is game code, and PlayerBase sits right above Player. GameConfig.h models the engine base that links at GameConfig's slot in KingSystem/System. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06snd: move sound actions and AIs to KingSystem/SoundLéo Lam
They link with KingSystem/Sound (0x7100fe8b54-0x7101060ed4) as sorted Action/AI passes of their own. The three area tag actions keep their game base AreaTagAction, which links in the Game/Actor/Area block. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-06Name placeholder declarations after the IDBLéo Lam
Keeps source and CSV from drifting from the IDB. Names are read from the bodies, e.g. ActionBase::applyParams is what all 13 non-stub overrides of that slot do. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-05world: implement Manager::isRaining (#214)Flatener
* world: implement Manager::isRaining Implement the position-based rain check for Rain, HeavyRain, ThunderRain, and BlueskyRain. Declare the climate weather lookup dependency and name both functions in the function table. The rain check matches the original function at 0x71010f33a4. * world: keep rainfall queries const Restore const on Manager::isRaining and make its climate weather helper const. Both queries only read Manager state. Update their function-table symbols; the rain check still matches the original.
2026-09-29OverlayArenaSystem: S2's delegate is a task delegateLéo Lam
The vtable its ctor installs (0x710251A960) is a Delegate1R<void*, bool>, and the callback returns bool. (AI assisted using Claude Opus 5.5)
2026-10-04gdt: rename IncreaseLogger to DeferredFlagWriterLéo Lam
It logs nothing: it queues flag increments per core and GameDataMgr::calc0 applies them once per frame. The IDB already uses this name. (AI assisted using Claude Opus 5.5)
2026-09-29aoc: fix the HardMode flag nameLéo Lam
The flag is "AoC_HardMode_Enabled", as 0x71008e3dbc returns; tools/check ignores string literals, so the misspelling still matched. (AI assisted using Claude Opus 5.5)
2026-10-04Move aiCameraEvent, AirOctaDataMgr, scenes, CameraMgrLéo Lam
Put each where link order does: aiCameraEvent in the camera AI run, AirOctaDataMgr right before aiAirOctaFlyUp, CameraMgr between the ActorSystem and Chemical runs. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-10-04vlt: move the heap helpers into vltLayerMgrTask.cppLéo Lam
The binary defines the HeapUtil.h helpers at the start of the LayerMgrTask TU: their statics sit just before LayerMgrTask::sInstance. (AI assisted using Claude Fable 5.1 and Claude Opus 5.5)
2026-09-08Document ContactPointInfo callback contractTarun Bandi
2026-07-30Merge pull request #185 from RobbyV2/phys-system-heap-accessorsMichael Zhao
Match phys::System heap accessors
2026-07-30phys: match System contact listener and group handler functionsRobbyV2
2026-07-30phys: match System heap accessorsRobbyV2
2026-07-29Merge pull request #182 from RobbyV2/actor-get-character-controllerMichael Zhao
Match Actor::getCharacterController
2026-07-28Match Actor::getCharacterControllerRobbyV2
2026-07-24ksys::phys::System: implement isPaused and collision/handler helpersmairokaizo
2026-07-11lib: Add xlink2 decomp as submoduleNitr4m12
2026-06-23various: fix mismatches in some action stubs and ResourceMgrTaskroot
2026-05-31fix new viking and update mismatchesPistonight
2026-02-15style: remove redundant virtual on override functions, fix SEAD_RTTI spacingJesse Dao
2026-01-14style: Fix coding guideline violationsJesse Dao
2025-11-01lib: Update `sead`MonsterDruide1
2025-06-19CreatePlayerEquipActorMgrPistonight
2025-06-18rename _c to lane_idPistonight
2025-05-24Reformat gdtSpecialFlags.cpp as wellLéo Lam
2025-05-24Reformat with clang-format 19.1Léo Lam
2025-05-17add at param helpersPistonight
2025-05-15merge BaseProcHandle and BaseProcUnit TUPistonight
2025-05-02add gdt flag name constant gettersPistonight