Skip to content

custom tunic fix#6022

Closed
Jameriquiah wants to merge 11 commits intoHarbourMasters:developfrom
Jameriquiah:develop
Closed

custom tunic fix#6022
Jameriquiah wants to merge 11 commits intoHarbourMasters:developfrom
Jameriquiah:develop

Conversation

@Jameriquiah
Copy link
Contributor

@Jameriquiah Jameriquiah commented Dec 14, 2025

this fixes the bug with custom tunics resetting on scene change.
reruns the custom skeleton code every frame. i couldnt come up with any other way to do this.
maybe could be tweaked to stop running if no custom tunic is used idk tho i suck at code.

tweaked it to use OnPlayerUpdate instead. doesnt update it in the pause menu but i dont really care. the customs skeletons still persist through scene changes

2025-12-14.15-28-05.mp4

@Jameriquiah Jameriquiah reopened this Dec 14, 2025
@Jameriquiah
Copy link
Contributor Author

woops didnt mean to close and reopen my apologies

Comment on lines +27 to +35
static HOOK_ID hookId = 0;

GameInteractor::Instance
->UnregisterGameHook<GameInteractor::OnGameFrameUpdate>(hookId);

hookId = GameInteractor::Instance
->RegisterGameHook<GameInteractor::OnGameFrameUpdate>(
OnGameFrameUpdateSkeletons
);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See code using COND_HOOK, ideally you would have bool for that only when this matters, but for unconditional usage you can use true as condition

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

was looking at other instances of COND_HOOK being used and im struggling to figure out how to apply it here with the desired result. im fairly new to coding so i dont really understand

@Malkierian
Copy link
Contributor

I can say that letting the code run every frame is almost certainly not going to be merged. That's far too heavy an operational cost. That being said, I don't know enough about the problem to be able to suggest any solutions.

@Jameriquiah
Copy link
Contributor Author

yea thats understandable. i tried other things too but nothing worked. like getting the code to run whenever a new scene is loaded but didnt fix it. truthfully im not even 100% sure why the problem happens to begin with, ive only theorized that perhaps the code runs, updates the player skeleton, then on scene change it just doesnt get ran again when link is reloaded onto a new scene. i also could be wrong idk.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants