diff --git a/runelite-api/src/main/java/net/runelite/api/Client.java b/runelite-api/src/main/java/net/runelite/api/Client.java index c4a3c89a00..d8528039a0 100644 --- a/runelite-api/src/main/java/net/runelite/api/Client.java +++ b/runelite-api/src/main/java/net/runelite/api/Client.java @@ -49,10 +49,14 @@ import org.slf4j.Logger; public interface Client extends GameShell { /** - * The client invokes these callbacks to communicate to + * The injected client invokes these callbacks to send events to us */ Callbacks getCallbacks(); + /** + * The injected client invokes these callbacks for scene drawing, which is + * used by the gpu plugin to override the client's normal scene drawing code + */ DrawCallbacks getDrawCallbacks(); void setDrawCallbacks(DrawCallbacks drawCallbacks); @@ -2001,6 +2005,7 @@ public interface Client extends GameShell void setGeSearchResultIndex(int index); /** +<<<<<<< HEAD * Sets values related to jagex compliance */ void setComplianceValue(@Nonnull String key, boolean value); @@ -2019,4 +2024,16 @@ public interface Client extends GameShell * Sets the status of client mirror */ void setMirrored(boolean isMirrored); + + /** + * Sets the image to be used for the login screen, provided as SpritePixels + * If the image is larger than half the width of fixed mode, + * it won't get mirrored to the other side of the screen + */ + void setLoginScreen(SpritePixels pixels); + + /** + * Sets whether the flames on the login screen should be rendered + */ + void setShouldRenderLoginScreenFire(boolean val); } diff --git a/runelite-api/src/main/java/net/runelite/api/VarPlayer.java b/runelite-api/src/main/java/net/runelite/api/VarPlayer.java index e399e400fb..999ef7a6b1 100644 --- a/runelite-api/src/main/java/net/runelite/api/VarPlayer.java +++ b/runelite-api/src/main/java/net/runelite/api/VarPlayer.java @@ -61,6 +61,15 @@ public enum VarPlayer */ AUTO_RETALIATE(172), + /** + * The ID of the party. This Var is only set in the raid bank area and the raid lobby + * + * This gets set to -1 when the raid starts. This is first set when the first player of the clan forms a party + * on the recruiting board and it changes again when the first person actually enters the raid. + * + * -1 : Not in a party or in the middle of an ongoing raid + * Anything else : This means that your clan has a raid party being formed and has not started yet + */ IN_RAID_PARTY(1427), NMZ_REWARD_POINTS(1060), diff --git a/runelite-client/src/main/java/net/runelite/client/menus/MenuManager.java b/runelite-client/src/main/java/net/runelite/client/menus/MenuManager.java index ae9a00665b..6631d1bcb7 100644 --- a/runelite-client/src/main/java/net/runelite/client/menus/MenuManager.java +++ b/runelite-client/src/main/java/net/runelite/client/menus/MenuManager.java @@ -448,9 +448,10 @@ public class MenuManager } } - if (event.getMenuOpcode() != MenuOpcode.RUNELITE) + if (event.getMenuAction() != MenuAction.RUNELITE + && event.getMenuAction() != MenuAction.RUNELITE_PLAYER) { - return; // not a player menu + return; // not a managed widget option or custom player option } int widgetId = event.getParam1(); @@ -483,7 +484,7 @@ public class MenuManager { client.getPlayerOptions()[playerOptionIndex] = menuText; client.getPlayerOptionsPriorities()[playerOptionIndex] = true; - client.getPlayerMenuTypes()[playerOptionIndex] = MenuOpcode.RUNELITE.getId(); + client.getPlayerMenuTypes()[playerOptionIndex] = MenuAction.RUNELITE_PLAYER.getId(); playerMenuIndexMap.put(playerOptionIndex, menuText); } diff --git a/runelite-client/src/main/java/net/runelite/client/ui/overlay/infobox/InfoBoxManager.java b/runelite-client/src/main/java/net/runelite/client/ui/overlay/infobox/InfoBoxManager.java index 8d74be368f..d992d8d181 100644 --- a/runelite-client/src/main/java/net/runelite/client/ui/overlay/infobox/InfoBoxManager.java +++ b/runelite-client/src/main/java/net/runelite/client/ui/overlay/infobox/InfoBoxManager.java @@ -70,8 +70,16 @@ public class InfoBoxManager log.debug("Adding InfoBox {}", infoBox); updateInfoBoxImage(infoBox); - infoBoxes.add(infoBox); - refreshInfoBoxes(); + + synchronized (this) + { + int idx = Collections.binarySearch(infoBoxes, infoBox, (b1, b2) -> ComparisonChain + .start() + .compare(b1.getPriority(), b2.getPriority()) + .compare(b1.getPlugin().getName(), b2.getPlugin().getName()) + .result()); + infoBoxes.add(idx < 0 ? -idx - 1 : idx, infoBox); + } BufferedImage image = infoBox.getImage();