Make the second argument of SpriteManager::getSprite work
I just blindly assumed that the arguments to net.runelite.cache.SpriteManager worked the same as Jagex's code, which is not true. In reality the second argument to getSprite(s?)asSpritePixels is always zero, and instead you have to decode the entire archive then select a sub image, rather than a subfile.
This commit is contained in:
@@ -318,9 +318,9 @@ public interface RSClient extends RSGameEngine, Client
|
||||
@Import("createSprite")
|
||||
RSSpritePixels createItemSprite(int itemId, int quantity, int thickness, int borderColor, int stackable, boolean noted);
|
||||
|
||||
@Import("getSpriteAsSpritePixels")
|
||||
@Import("getSpritesAsSpritePixels")
|
||||
@Override
|
||||
RSSpritePixels getSprite(IndexDataBase source, int archiveId, int fileId);
|
||||
RSSpritePixels[] getSprites(IndexDataBase source, int archiveId, int fileId);
|
||||
|
||||
@Import("indexSprites")
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user