Infinitay / essence-pouch-tracker

A RuneLite plugin that tracks both the amount of essence stored in your essence pouches and the amount of essence until decay.
https://runelite.net/plugin-hub/show/essence-pouch-tracking
BSD 2-Clause "Simplified" License
0 stars 1 forks source link

[Request] Support colossal pouch at lower Runecrafting levels #52

Closed Tyler799 closed 1 week ago

Tyler799 commented 1 week ago

The patch on November 13th 2024 added the ability for players to create the colossal pouch below level 85. Its capacity at lower levels mimics what the lower level pouches would hold, minus the extra space you save from not needing to keep them in your inventory. See this wiki page for the exact numbers: https://oldschool.runescape.wiki/w/Colossal_pouch

Right now, the plugin appears to still think it will always hold 40 - so if you're lower level the plugin will report incorrect counts on the amount inside the pouch as well as the amount it has degraded.

Infinitay commented 1 week ago

I just finished working on this but have yet to test the changes made to make sure things are working smoothly. Thanks for bringing it up though!

mikeweyandt commented 1 week ago

If you throw the changes into a dev branch I can give it a quick test as well!

Infinitay commented 1 week ago

If you throw the changes into a dev branch I can give it a quick test as well!

If I saw this sooner lol. Sorry, I just noticed the reply when I came and slowly did the testing myself. Although, I had to rely on RuneLite's ability to fake stat levels so there could be underlying issues. If you would still like to take the time to test the plugin then that would be appreciated. I'm not going to merge the changes yet for that reason and will merge it sometime around 10 AM to 1 PM PST.

Thanks.

mikeweyandt commented 1 week ago

Taking a look! First try it's just reporting 8 essence (I have lvl 71 rc), when it should be 16, taking a look to see what's happening

Infinitay commented 1 week ago

Taking a look! First try it's just reporting 8 essence (I have lvl 71 rc), when it should be 16, taking a look to see what's happening

I think I figured out the issue. When you first login, ItemContainerChanged is fired before the [client retrieves a player's skill level](https://static.runelite.net/api/runelite-api/net/runelite/api/Client.html#getRealSkillLevels()) whenever you login after a cold start/fresh RL instance. Oddly, switching to a different account doesn't face this issue. I'll work on fixing it. I want to see if I can avoid adding a workaround to be ran when the first game tick is received. Otherwise, I'll implement that solution.

Seems like GameTick is the only way. I'll work on the fix. Although since I'll now have to wait a few ticks (XpTracker's plugin waits at least 2 game ticks itself, I'm debating on making it so you can't empty/fill a pouch within those first 2 ticks of logging into RS to avoid any issues.

Infinitay commented 1 week ago

@mikeweyandt Could you verify the latest changes fixed your problem whenever you find the time to do so? I tested it myself by faking my stats, but having your input would be appreciated.

Infinitay commented 1 week ago

I've pushed the changes to the plugin hub and current awaiting approval: https://github.com/runelite/plugin-hub/pull/6970