Merge remote-tracking branch 'runelite/master'

This commit is contained in:
Owain van Brakel
2022-01-19 18:35:40 +01:00
37 changed files with 1061 additions and 365 deletions

View File

@@ -83,6 +83,7 @@ public class DpsCounterPlugin extends Plugin
KREEARRA, KREEARRA_6492,
KRIL_TSUTSAROTH, KRIL_TSUTSAROTH_6495,
THE_MIMIC, THE_MIMIC_8633,
NEX, NEX_11279, NEX_11280, NEX_11281, NEX_11282,
THE_NIGHTMARE, THE_NIGHTMARE_9426, THE_NIGHTMARE_9427, THE_NIGHTMARE_9428, THE_NIGHTMARE_9429, THE_NIGHTMARE_9430, THE_NIGHTMARE_9431, THE_NIGHTMARE_9432, THE_NIGHTMARE_9433,
OBOR,
SARACHNIS,

View File

@@ -436,4 +436,15 @@ public interface GroundItemsConfig extends Config
{
return HighlightTier.HIGH;
}
@ConfigItem(
keyName = "lootbeamStyle",
name = "Lootbeam Style",
description = "Style of lootbeam to use",
position = 32
)
default Lootbeam.Style lootbeamStyle()
{
return Lootbeam.Style.MODERN;
}
}

View File

@@ -99,7 +99,7 @@ import net.runelite.client.util.Text;
@PluginDescriptor(
name = "Ground Items",
description = "Highlight ground items and/or show price information",
tags = {"grand", "exchange", "high", "alchemy", "prices", "highlight", "overlay"}
tags = {"grand", "exchange", "high", "alchemy", "prices", "highlight", "overlay", "lootbeam"}
)
public class GroundItemsPlugin extends Plugin
{
@@ -791,12 +791,13 @@ public class GroundItemsPlugin extends Plugin
Lootbeam lootbeam = lootbeams.get(worldPoint);
if (lootbeam == null)
{
lootbeam = new Lootbeam(client, clientThread, worldPoint, color);
lootbeam = new Lootbeam(client, clientThread, worldPoint, color, config.lootbeamStyle());
lootbeams.put(worldPoint, lootbeam);
}
else
{
lootbeam.setColor(color);
lootbeam.setStyle(config.lootbeamStyle());
}
}

View File

@@ -24,10 +24,14 @@
*/
package net.runelite.client.plugins.grounditems;
import java.util.function.Function;
import lombok.RequiredArgsConstructor;
import net.runelite.api.Animation;
import net.runelite.api.AnimationID;
import net.runelite.api.Client;
import net.runelite.api.JagexColor;
import net.runelite.api.Model;
import net.runelite.api.ModelData;
import net.runelite.api.RuneLiteObject;
import net.runelite.api.coords.LocalPoint;
import net.runelite.api.coords.WorldPoint;
@@ -36,22 +40,58 @@ import net.runelite.client.callback.ClientThread;
class Lootbeam
{
private static final int RAID_LIGHT_MODEL = 5809;
private static final short RAID_LIGHT_FIND_COLOR = 6371;
private final RuneLiteObject runeLiteObject;
private final Client client;
private final ClientThread clientThread;
private Color color;
private Style style;
public Lootbeam(Client client, ClientThread clientThread, WorldPoint worldPoint, Color color)
@RequiredArgsConstructor
public enum Style
{
LIGHT(l -> l.client.loadModel(
5809,
new short[]{6371},
new short[]{JagexColor.rgbToHSL(l.color.getRGB(), 1.0d)}
), anim(AnimationID.RAID_LIGHT_ANIMATION)),
MODERN(l ->
{
ModelData md = l.client.loadModelData(43330);
if (md == null)
{
return null;
}
short hsl = JagexColor.rgbToHSL(l.color.getRGB(), 1.0d);
int hue = JagexColor.unpackHue(hsl);
int sat = Math.min(JagexColor.unpackSaturation(hsl) + 1, JagexColor.SATURATION_MAX);
int lum = JagexColor.unpackLuminance(hsl);
return md.cloneColors()
.recolor((short) 26432, JagexColor.packHSL(hue, sat, Math.min(lum + 12, JagexColor.LUMINANCE_MAX)))
.recolor((short) 26584, JagexColor.packHSL(hue, sat - 1, Math.max(lum - 12, 0)))
.light(75, 1875, ModelData.DEFAULT_X, ModelData.DEFAULT_Y, ModelData.DEFAULT_Z);
}, anim(AnimationID.LOOTBEAM_ANIMATION)),
;
private final Function<Lootbeam, Model> modelSupplier;
private final Function<Lootbeam, Animation> animationSupplier;
}
private static Function<Lootbeam, Animation> anim(int id)
{
return b -> b.client.loadAnimation(id);
}
public Lootbeam(Client client, ClientThread clientThread, WorldPoint worldPoint, Color color, Style style)
{
this.client = client;
this.clientThread = clientThread;
runeLiteObject = client.createRuneLiteObject();
setColor(color);
runeLiteObject.setAnimation(client.loadAnimation(AnimationID.RAID_LIGHT_ANIMATION));
this.color = color;
this.style = style;
update();
runeLiteObject.setShouldLoop(true);
LocalPoint lp = LocalPoint.fromWorld(client, worldPoint);
@@ -68,19 +108,34 @@ class Lootbeam
}
this.color = color;
update();
}
public void setStyle(Style style)
{
if (this.style == style)
{
return;
}
this.style = style;
update();
}
private void update()
{
clientThread.invoke(() ->
{
Model m = client.loadModel(
RAID_LIGHT_MODEL,
new short[]{RAID_LIGHT_FIND_COLOR},
new short[]{JagexColor.rgbToHSL(color.getRGB(), 1.0d)}
);
if (m == null)
Model model = style.modelSupplier.apply(this);
if (model == null)
{
return false;
}
runeLiteObject.setModel(m);
Animation anim = style.animationSupplier.apply(this);
runeLiteObject.setAnimation(anim);
runeLiteObject.setModel(model);
return true;
});
}

View File

@@ -46,6 +46,7 @@ public interface ItemChargeConfig extends Config
String KEY_EXPEDITIOUS_BRACELET = "expeditiousBracelet";
String KEY_EXPLORERS_RING = "explorerRing";
String KEY_RING_OF_FORGING = "ringOfForging";
String KEY_BLOOD_ESSENCE = "bloodEssence";
@ConfigSection(
name = "Charge Settings",
@@ -415,4 +416,16 @@ public interface ItemChargeConfig extends Config
{
return true;
}
@ConfigItem(
keyName = "showBloodEssenceCharges",
name = "Blood Essence Charges",
description = "Show Blood Essence charges",
position = 30,
section = chargesSection
)
default boolean showBloodEssenceCharges()
{
return true;
}
}

View File

@@ -130,6 +130,13 @@ public class ItemChargePlugin extends Plugin
"Your expeditious bracelet has (\\d{1,2}) charges? left\\."
);
private static final String EXPEDITIOUS_BRACELET_BREAK_TEXT = "Your Expeditious Bracelet has crumbled to dust.";
private static final Pattern BLOOD_ESSENCE_CHECK_PATTERN = Pattern.compile(
"Your blood essence has (\\d{1,4}) charges? remaining"
);
private static final Pattern BLOOD_ESSENCE_EXTRACT_PATTERN = Pattern.compile(
"You manage to extract power from the Blood Essence and craft (\\d{1,3}) extra runes?\\."
);
private static final String BLOOD_ESSENCE_ACTIVATE_TEXT = "You activate the blood essence.";
private static final int MAX_DODGY_CHARGES = 10;
private static final int MAX_BINDING_CHARGES = 16;
@@ -138,6 +145,7 @@ public class ItemChargePlugin extends Plugin
private static final int MAX_AMULET_OF_CHEMISTRY_CHARGES = 5;
private static final int MAX_AMULET_OF_BOUNTY_CHARGES = 10;
private static final int MAX_SLAYER_BRACELET_CHARGES = 30;
private static final int MAX_BLOOD_ESSENCE_CHARGES = 1000;
private int lastExplorerRingCharge = -1;
@@ -227,6 +235,8 @@ public class ItemChargePlugin extends Plugin
Matcher slaughterCheckMatcher = BRACELET_OF_SLAUGHTER_CHECK_PATTERN.matcher(message);
Matcher expeditiousActivateMatcher = EXPEDITIOUS_BRACELET_ACTIVATE_PATTERN.matcher(message);
Matcher expeditiousCheckMatcher = EXPEDITIOUS_BRACELET_CHECK_PATTERN.matcher(message);
Matcher bloodEssenceCheckMatcher = BLOOD_ESSENCE_CHECK_PATTERN.matcher(message);
Matcher bloodEssenceExtractMatcher = BLOOD_ESSENCE_EXTRACT_PATTERN.matcher(message);
if (config.recoilNotification() && message.contains(RING_OF_RECOIL_BREAK_MESSAGE))
{
@@ -413,6 +423,18 @@ public class ItemChargePlugin extends Plugin
{
updateExpeditiousBraceletCharges(Integer.parseInt(expeditiousCheckMatcher.group(1)));
}
else if (bloodEssenceCheckMatcher.find())
{
updateBloodEssenceCharges(Integer.parseInt(bloodEssenceCheckMatcher.group(1)));
}
else if (bloodEssenceExtractMatcher.find())
{
updateBloodEssenceCharges(getItemCharges(ItemChargeConfig.KEY_BLOOD_ESSENCE) - Integer.parseInt(bloodEssenceExtractMatcher.group(1)));
}
else if (message.contains(BLOOD_ESSENCE_ACTIVATE_TEXT))
{
updateBloodEssenceCharges(MAX_BLOOD_ESSENCE_CHARGES);
}
}
}
@@ -540,6 +562,12 @@ public class ItemChargePlugin extends Plugin
updateInfoboxes();
}
private void updateBloodEssenceCharges(final int value)
{
setItemCharges(ItemChargeConfig.KEY_BLOOD_ESSENCE, value);
updateInfoboxes();
}
private void checkDestroyWidget()
{
final int currentTick = client.getTickCount();

View File

@@ -51,7 +51,8 @@ enum ItemChargeType
SACK(ItemChargeConfig::showSackCharges),
RING_OF_FORGING(ItemChargeConfig::showRingOfForgingCount),
POTION(ItemChargeConfig::showPotionDoseCount),
GUTHIX_REST(ItemChargeConfig::showGuthixRestDoses);
GUTHIX_REST(ItemChargeConfig::showGuthixRestDoses),
BLOOD_ESSENCE(ItemChargeConfig::showBloodEssenceCharges);
private final Predicate<ItemChargeConfig> enabled;
}

View File

@@ -62,6 +62,10 @@ enum ItemWithCharge
ANTIDOTE_PP2(POTION, ANTIDOTE2_5956, 2),
ANTIDOTE_PP3(POTION, ANTIDOTE3_5954, 3),
ANTIDOTE_PP4(POTION, ANTIDOTE4_5952, 4),
ANCIENT_BR1(POTION, ANCIENT_BREW1, 1),
ANCIENT_BR2(POTION, ANCIENT_BREW2, 2),
ANCIENT_BR3(POTION, ANCIENT_BREW3, 3),
ANCIENT_BR4(POTION, ANCIENT_BREW4, 4),
ANTIFIRE1(POTION, ANTIFIRE_POTION1, 1),
ANTIFIRE2(POTION, ANTIFIRE_POTION2, 2),
ANTIFIRE3(POTION, ANTIFIRE_POTION3, 3),

View File

@@ -46,7 +46,8 @@ enum ItemWithConfig
AMULET_OF_BOUNTY(ItemID.AMULET_OF_BOUNTY, ItemChargeConfig.KEY_AMULET_OF_BOUNTY, ItemChargeType.AMULET_OF_BOUNTY),
BRACELET_OF_SLAUGHTER(ItemID.BRACELET_OF_SLAUGHTER, ItemChargeConfig.KEY_BRACELET_OF_SLAUGHTER, ItemChargeType.BRACELET_OF_SLAUGHTER),
EXPEDITIOUS_BRACELET(ItemID.EXPEDITIOUS_BRACELET, ItemChargeConfig.KEY_EXPEDITIOUS_BRACELET, ItemChargeType.EXPEDITIOUS_BRACELET),
CHRONICLE(ItemID.CHRONICLE, ItemChargeConfig.KEY_CHRONICLE, ItemChargeType.TELEPORT);
CHRONICLE(ItemID.CHRONICLE, ItemChargeConfig.KEY_CHRONICLE, ItemChargeType.TELEPORT),
BLOOD_ESSENCE(ItemID.BLOOD_ESSENCE_ACTIVE, ItemChargeConfig.KEY_BLOOD_ESSENCE, ItemChargeType.BLOOD_ESSENCE);
private final int itemId;
private final String configKey;

View File

@@ -293,6 +293,7 @@ enum ItemIdentification
ZAMORAK_BREW(Type.POTION, "ZammyBr", "Za", ItemID.ZAMORAK_BREW4, ItemID.ZAMORAK_BREW3, ItemID.ZAMORAK_BREW2, ItemID.ZAMORAK_BREW1),
SARADOMIN_BREW(Type.POTION, "SaraBr", "Sa", ItemID.SARADOMIN_BREW4, ItemID.SARADOMIN_BREW3, ItemID.SARADOMIN_BREW2, ItemID.SARADOMIN_BREW1),
ANCIENT_BREW(Type.POTION, "AncBr", "A.Br", ItemID.ANCIENT_BREW4, ItemID.ANCIENT_BREW3, ItemID.ANCIENT_BREW2, ItemID.ANCIENT_BREW1),
ANTIPOISON(Type.POTION, "AntiP", "AP", ItemID.ANTIPOISON4, ItemID.ANTIPOISON3, ItemID.ANTIPOISON2, ItemID.ANTIPOISON1),
SUPERANTIPOISON(Type.POTION, "S.AntiP", "S.AP", ItemID.SUPERANTIPOISON4, ItemID.SUPERANTIPOISON3, ItemID.SUPERANTIPOISON2, ItemID.SUPERANTIPOISON1),

View File

@@ -44,6 +44,7 @@ public enum LoginScreenOverride
PRIFDDINAS("prifddinas.jpg"),
THEATRE_OF_BLOOD("tob.jpg"),
A_KINGDOM_DIVIDED("akd.jpg"),
NEX("nex.jpg"),
CUSTOM,
RANDOM;

View File

@@ -787,6 +787,35 @@ public interface MenuEntrySwapperConfig extends Config
return false;
}
enum StairsMode
{
CLIMB,
CLIMB_UP,
CLIMB_DOWN,
}
@ConfigItem(
keyName = "swapStairsLeftClick",
name = "Stairs left-click",
description = "Swap this option when left-clicking stairs. Also works on ladders.",
section = objectSection
)
default StairsMode swapStairsLeftClick()
{
return StairsMode.CLIMB;
}
@ConfigItem(
keyName = "swapStairsShiftClick",
name = "Stairs shift-click",
description = "Swap this option when shift-clicking stairs. Also works on ladders.",
section = objectSection
)
default StairsMode swapStairsShiftClick()
{
return StairsMode.CLIMB;
}
@ConfigItem(
keyName = "swapTemporossLeave",
name = "Tempoross Leave",

View File

@@ -416,6 +416,9 @@ public class MenuEntrySwapperPlugin extends Plugin
swap("eat", "guzzle", config::swapRockCake);
swap("travel", "dive", config::swapRowboatDive);
swap("climb", "climb-up", () -> (shiftModifier() ? config.swapStairsShiftClick() : config.swapStairsLeftClick()) == MenuEntrySwapperConfig.StairsMode.CLIMB_UP);
swap("climb", "climb-down", () -> (shiftModifier() ? config.swapStairsShiftClick() : config.swapStairsLeftClick()) == MenuEntrySwapperConfig.StairsMode.CLIMB_DOWN);
}
public Swap swap(String option, String swappedOption, Supplier<Boolean> enabled)
@@ -614,17 +617,19 @@ public class MenuEntrySwapperPlugin extends Plugin
final boolean isDepositBoxPlayerInventory = widgetGroupId == WidgetID.DEPOSIT_BOX_GROUP_ID;
final boolean isChambersOfXericStorageUnitPlayerInventory = widgetGroupId == WidgetID.CHAMBERS_OF_XERIC_STORAGE_UNIT_INVENTORY_GROUP_ID;
final boolean isGroupStoragePlayerInventory = widgetGroupId == WidgetID.GROUP_STORAGE_INVENTORY_GROUP_ID;
// Swap to shift-click deposit behavior
// Deposit- op 1 is the current withdraw amount 1/5/10/x for deposit box interface and chambers of xeric storage unit.
// Deposit- op 2 is the current withdraw amount 1/5/10/x for bank interface
if (shiftModifier() && config.bankDepositShiftClick() != ShiftDepositMode.OFF
&& menuEntryAdded.getType() == MenuAction.CC_OP.getId()
&& menuEntryAdded.getIdentifier() == (isDepositBoxPlayerInventory || isChambersOfXericStorageUnitPlayerInventory ? 1 : 2)
&& menuEntryAdded.getIdentifier() == (isDepositBoxPlayerInventory || isGroupStoragePlayerInventory || isChambersOfXericStorageUnitPlayerInventory ? 1 : 2)
&& (menuEntryAdded.getOption().startsWith("Deposit-") || menuEntryAdded.getOption().startsWith("Store") || menuEntryAdded.getOption().startsWith("Donate")))
{
ShiftDepositMode shiftDepositMode = config.bankDepositShiftClick();
final int opId = isDepositBoxPlayerInventory ? shiftDepositMode.getIdentifierDepositBox()
: isChambersOfXericStorageUnitPlayerInventory ? shiftDepositMode.getIdentifierChambersStorageUnit()
: isGroupStoragePlayerInventory ? shiftDepositMode.getIdentifierGroupStorage()
: shiftDepositMode.getIdentifier();
final MenuAction action = opId >= 6 ? MenuAction.CC_OP_LOW_PRIORITY : MenuAction.CC_OP;
bankModeSwap(action, opId);

View File

@@ -31,17 +31,18 @@ import lombok.RequiredArgsConstructor;
@RequiredArgsConstructor
public enum ShiftDepositMode
{
DEPOSIT_1("Deposit-1", 3, 2, 1),
DEPOSIT_5("Deposit-5", 4, 3, 2),
DEPOSIT_10("Deposit-10", 5, 4, 3),
DEPOSIT_X("Deposit-X", 6, 6, 5),
DEPOSIT_ALL("Deposit-All", 8, 5, 4),
EXTRA_OP("Eat/Wield/Etc.", 9, 9, 0),
OFF("Off", 0, 0, 0);
DEPOSIT_1("Deposit-1", 3, 2, 1, 1),
DEPOSIT_5("Deposit-5", 4, 3, 3, 2),
DEPOSIT_10("Deposit-10", 5, 4, 4, 3),
DEPOSIT_X("Deposit-X", 6, 6, 5, 5),
DEPOSIT_ALL("Deposit-All", 8, 5, 7, 4),
EXTRA_OP("Eat/Wield/Etc.", 9, 9, 0, 0),
OFF("Off", 0, 0, 0, 0);
private final String name;
private final int identifier;
private final int identifierDepositBox;
private final int identifierGroupStorage;
private final int identifierChambersStorageUnit;
@Override

View File

@@ -94,6 +94,7 @@ public enum HerbloreAction implements ItemSkillAction
WEAPON_POISON_PLUS_PLUS(ItemID.WEAPON_POISON_5940, 82, 190),
EXTENDED_ANTIFIRE_3(ItemID.EXTENDED_ANTIFIRE3, 84, 82.5f),
EXTENDED_ANTIFIRE_4(ItemID.EXTENDED_ANTIFIRE4, 84, 110),
ANCIENT_BREW_4(ItemID.ANCIENT_BREW4, 85, 190),
DIVINE_BASTION_POTION_4(ItemID.DIVINE_BASTION_POTION4, 86, 2),
DIVINE_BATTLEMAGE_POTION_4(ItemID.DIVINE_BATTLEMAGE_POTION4, 86, 2),
ANTIVENOM_3(ItemID.ANTIVENOM3, 87, 90),

View File

@@ -144,7 +144,8 @@ enum MiningSiteLocation
LOVAKENGJ_SOUTH(new WorldPoint(1476, 3779, 0), new Rock(4, Ore.IRON), new Rock(6, Ore.COAL), new Rock(1, Ore.MITHRIL)),
LOVAKENGJ_SULPHUR_EAST(new WorldPoint(1445, 3870, 0), new Rock(3, Ore.VOLCANIC_SULPHUR)),
LOVAKENGJ_SULPHUR_WEST(new WorldPoint(1427, 3870, 0), new Rock(2, Ore.VOLCANIC_SULPHUR)),
LOVAKENGJ_WEST(new WorldPoint(1432, 3845, 0), true, new Rock(45, Ore.COAL), new Rock(80, Ore.LOVAKITE)),
LOVAKENGJ_WEST_1(new WorldPoint(1430, 3849, 0), new Rock(33, Ore.COAL), new Rock(58, Ore.LOVAKITE)),
LOVAKENGJ_WEST_2(new WorldPoint(1447, 3840, 0), new Rock(12, Ore.COAL), new Rock(22, Ore.LOVAKITE)),
LUMBRIDGE_SWAMP_EAST(new WorldPoint(3226, 3146, 0), new Rock(5, Ore.COPPER), new Rock(5, Ore.TIN)),
LUMBRIDGE_SWAMP_WEST(new WorldPoint(3148, 3149, 0),
new Rock(7, Ore.COAL), new Rock(5, Ore.MITHRIL), new Rock(2, Ore.ADAMANTITE)),

View File

@@ -168,7 +168,7 @@ public class ClientUI
this.clientThreadProvider = clientThreadProvider;
this.eventBus = eventBus;
this.safeMode = safeMode;
this.title = RuneLiteProperties.getTitle();
this.title = RuneLiteProperties.getTitle() + (safeMode ? " (safe mode)" : "");
}
@Subscribe

View File

@@ -3,6 +3,22 @@
1,
4051
],
"cannon base": [
6,
26520
],
"cannon stand": [
8,
26522
],
"cannon barrels": [
10,
26524
],
"cannon furnace": [
12,
26526
],
"excalibur": [
35,
8280
@@ -2483,7 +2499,9 @@
24971,
24973,
24994,
24996
24996,
26417,
26419
],
"empty cup": [
1980,
@@ -3297,6 +3315,18 @@
12609,
12611
],
"holy book": [
3840,
26496
],
"unholy book": [
3842,
26498
],
"book of balance": [
3844,
26488
],
"games necklace": [
3853,
3855,
@@ -3499,34 +3529,39 @@
4099,
4109,
20562,
23047
23047,
26531
],
"mystic robe top": [
4091,
4101,
4111,
20425,
23050
23050,
26533
],
"mystic robe bottom": [
4093,
4103,
4113,
20426,
23053
23053,
26535
],
"mystic gloves": [
4095,
4105,
4115,
23056
23056,
26537
],
"mystic boots": [
4097,
4107,
4117,
20579,
23059
23059,
26539
],
"crawling hand": [
4133,
@@ -3542,7 +3577,8 @@
4178,
12773,
12774,
20405
20405,
26482
],
"granite maul": [
4153,
@@ -6124,12 +6160,14 @@
"void knight top": [
8839,
20465,
24177
24177,
26463
],
"void knight robe": [
8840,
20469,
24179
24179,
26465
],
"void knight mace": [
8841,
@@ -6139,7 +6177,8 @@
"void knight gloves": [
8842,
20475,
24182
24182,
26467
],
"bronze defender": [
8844,
@@ -6359,7 +6398,8 @@
],
"rune crossbow": [
9185,
23601
23601,
26486
],
"jade bolts": [
9237,
@@ -7260,17 +7300,20 @@
"void mage helm": [
11663,
20477,
24183
24183,
26473
],
"void ranger helm": [
11664,
20479,
24184
24184,
26475
],
"void melee helm": [
11665,
20481,
24185
24185,
26477
],
"void seal": [
11666,
@@ -7620,6 +7663,10 @@
19720,
23654
],
"abyssal tentacle": [
12006,
26484
],
"soft clay pack": [
12009,
12010,
@@ -7649,6 +7696,18 @@
12692,
25256
],
"book of war": [
12608,
26494
],
"book of law": [
12610,
26492
],
"book of darkness": [
12612,
26490
],
"bandos page": [
12613,
12614,
@@ -7999,12 +8058,14 @@
"elite void top": [
13072,
20467,
24178
24178,
26469
],
"elite void robe": [
13073,
20471,
24180
24180,
26471
],
"crystal halberd": [
13080,
@@ -10240,5 +10301,37 @@
"blood essence": [
26390,
26392
],
"shattered hood": [
26427,
26439,
26451
],
"shattered top": [
26430,
26442,
26454
],
"shattered trousers": [
26433,
26445,
26457
],
"shattered boots": [
26436,
26448,
26460
],
"unidentified fragment": [
26544,
26545,
26546,
26547,
26548
],
"shattered relic hunter armour set": [
26554,
26557,
26560
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 KiB

View File

@@ -1 +1 @@
C85469C2529D794C523505679F14AA20E988513E8FBAF249E41F4760382B4BBB
49856301491D162091426F3F788EA13FDBE3E5BE758471537F5E7AB7A588066B

View File

@@ -12,259 +12,224 @@
iconst 105
iconst 83
iconst 681
get_varc_int 207
coordx
get_varc_int 953
enum
iload 0
if_icmpeq LABEL9
jump LABEL16
LABEL9:
get_varc_int 207
iconst 0
iconst 0
if_icmpeq LABEL8
jump LABEL13
LABEL8:
get_varc_int 960
iload 1
movecoord
set_varc_int 207
jump LABEL227
LABEL16:
add
set_varc_int 960
jump LABEL192
LABEL13:
iconst 105
iconst 83
iconst 681
get_varc_int 208
coordx
get_varc_int 954
enum
iload 0
if_icmpeq LABEL25
jump LABEL32
LABEL25:
get_varc_int 208
iconst 0
iconst 0
if_icmpeq LABEL21
jump LABEL26
LABEL21:
get_varc_int 961
iload 1
movecoord
set_varc_int 208
jump LABEL227
LABEL32:
add
set_varc_int 961
jump LABEL192
LABEL26:
iconst 105
iconst 83
iconst 681
get_varc_int 209
coordx
get_varc_int 955
enum
iload 0
if_icmpeq LABEL41
jump LABEL48
LABEL41:
get_varc_int 209
iconst 0
iconst 0
if_icmpeq LABEL34
jump LABEL39
LABEL34:
get_varc_int 962
iload 1
movecoord
set_varc_int 209
jump LABEL227
LABEL48:
add
set_varc_int 962
jump LABEL192
LABEL39:
iconst 105
iconst 83
iconst 681
get_varc_int 210
coordx
get_varc_int 956
enum
iload 0
if_icmpeq LABEL57
jump LABEL64
LABEL57:
get_varc_int 210
iconst 0
iconst 0
if_icmpeq LABEL47
jump LABEL52
LABEL47:
get_varc_int 963
iload 1
movecoord
set_varc_int 210
jump LABEL227
LABEL64:
add
set_varc_int 963
jump LABEL192
LABEL52:
iconst 105
iconst 83
iconst 681
get_varc_int 211
coordx
get_varc_int 957
enum
iload 0
if_icmpeq LABEL60
jump LABEL65
LABEL60:
get_varc_int 964
iload 1
add
set_varc_int 964
jump LABEL192
LABEL65:
iconst 105
iconst 83
iconst 681
get_varc_int 958
enum
iload 0
if_icmpeq LABEL73
jump LABEL80
jump LABEL78
LABEL73:
get_varc_int 211
iconst 0
iconst 0
get_varc_int 965
iload 1
movecoord
set_varc_int 211
jump LABEL227
LABEL80:
add
set_varc_int 965
jump LABEL192
LABEL78:
iconst 105
iconst 83
iconst 681
get_varc_int 212
coordx
get_varc_int 959
enum
iload 0
if_icmpeq LABEL89
jump LABEL96
LABEL89:
get_varc_int 212
iconst 0
iconst 0
if_icmpeq LABEL86
jump LABEL91
LABEL86:
get_varc_int 966
iload 1
movecoord
set_varc_int 212
jump LABEL227
LABEL96:
iconst 105
iconst 83
iconst 681
get_varc_int 213
coordx
enum
iload 0
if_icmpeq LABEL105
jump LABEL112
LABEL105:
get_varc_int 213
iconst 0
iconst 0
iload 1
movecoord
set_varc_int 213
jump LABEL227
LABEL112:
add
set_varc_int 966
jump LABEL192
LABEL91:
iload 0
iconst 3
if_icmpeq LABEL116
jump LABEL123
LABEL116:
if_icmpeq LABEL95
jump LABEL102
LABEL95:
iload 1
iconst 20000001
if_icmpeq LABEL120
jump LABEL123
LABEL120:
iconst 269500481
set_varc_int 207
jump LABEL227
LABEL123:
get_varc_int 207
if_icmpeq LABEL99
jump LABEL102
LABEL99:
iconst -10
set_varc_int 960
jump LABEL192
LABEL102:
get_varc_int 953
iconst -1
if_icmpeq LABEL127
jump LABEL138
LABEL127:
iconst 0
if_icmpeq LABEL106
jump LABEL115
LABEL106:
iconst 83
iconst 105
iconst 81
iload 0
enum
iconst 0
set_varc_int 953
iload 1
movecoord
set_varc_int 207
jump LABEL227
LABEL138:
get_varc_int 208
set_varc_int 960
jump LABEL192
LABEL115:
get_varc_int 954
iconst -1
if_icmpeq LABEL142
jump LABEL153
LABEL142:
iconst 0
if_icmpeq LABEL119
jump LABEL128
LABEL119:
iconst 83
iconst 105
iconst 81
iload 0
enum
iconst 0
set_varc_int 954
iload 1
movecoord
set_varc_int 208
jump LABEL227
LABEL153:
get_varc_int 209
set_varc_int 961
jump LABEL192
LABEL128:
get_varc_int 955
iconst -1
if_icmpeq LABEL157
jump LABEL168
LABEL157:
iconst 0
if_icmpeq LABEL132
jump LABEL141
LABEL132:
iconst 83
iconst 105
iconst 81
iload 0
enum
iconst 0
set_varc_int 955
iload 1
movecoord
set_varc_int 209
jump LABEL227
LABEL168:
get_varc_int 210
set_varc_int 962
jump LABEL192
LABEL141:
get_varc_int 956
iconst -1
if_icmpeq LABEL172
jump LABEL183
LABEL172:
iconst 0
if_icmpeq LABEL145
jump LABEL154
LABEL145:
iconst 83
iconst 105
iconst 81
iload 0
enum
iconst 0
set_varc_int 956
iload 1
movecoord
set_varc_int 210
jump LABEL227
LABEL183:
get_varc_int 211
set_varc_int 963
jump LABEL192
LABEL154:
get_varc_int 957
iconst -1
if_icmpeq LABEL187
jump LABEL198
LABEL187:
iconst 0
if_icmpeq LABEL158
jump LABEL167
LABEL158:
iconst 83
iconst 105
iconst 81
iload 0
enum
iconst 0
set_varc_int 957
iload 1
movecoord
set_varc_int 211
jump LABEL227
LABEL198:
get_varc_int 212
set_varc_int 964
jump LABEL192
LABEL167:
get_varc_int 958
iconst -1
if_icmpeq LABEL202
jump LABEL213
LABEL202:
iconst 0
if_icmpeq LABEL171
jump LABEL180
LABEL171:
iconst 83
iconst 105
iconst 81
iload 0
enum
iconst 0
set_varc_int 958
iload 1
movecoord
set_varc_int 212
jump LABEL227
LABEL213:
get_varc_int 213
set_varc_int 965
jump LABEL192
LABEL180:
get_varc_int 959
iconst -1
if_icmpeq LABEL217
jump LABEL227
LABEL217:
iconst 0
if_icmpeq LABEL184
jump LABEL192
LABEL184:
iconst 83
iconst 105
iconst 81
iload 0
enum
iconst 0
set_varc_int 959
iload 1
movecoord
set_varc_int 213
LABEL227:
set_varc_int 966
LABEL192:
return

View File

@@ -93,6 +93,10 @@ public class ItemChargePluginTest
private static final String ACTIVATE_EXPEDITIOUS_BRACELET = "Your expeditious bracelet helps you progress your slayer task faster. It has 11 charges left.";
private static final String BREAK_EXPEDITIOUS_BRACELET = "Your expeditious bracelet helps you progress your slayer task faster. <col=ff0000>It then crumbles to dust.</col>";
private static final String ACTIVATE_BLOOD_ESSENCE = "You activate the blood essence.";
private static final String EXTRACT_BLOOD_ESSENCE = "You manage to extract power from the Blood Essence and craft 67 extra runes.";
private static final String CHECK_BLOOD_ESSENCE = "Your blood essence has 56 charges remaining";
@Mock
@Bind
private Client client;
@@ -421,4 +425,29 @@ public class ItemChargePluginTest
itemChargePlugin.onChatMessage(chatMessage);
verify(configManager).setRSProfileConfiguration(ItemChargeConfig.GROUP, ItemChargeConfig.KEY_EXPEDITIOUS_BRACELET, 30);
}
@Test
public void testBloodEssenceActivate()
{
ChatMessage chatMessage = new ChatMessage(null, ChatMessageType.GAMEMESSAGE, "", ACTIVATE_BLOOD_ESSENCE, "", 0);
itemChargePlugin.onChatMessage(chatMessage);
verify(configManager).setRSProfileConfiguration(ItemChargeConfig.GROUP, ItemChargeConfig.KEY_BLOOD_ESSENCE, 1000);
}
@Test
public void testBloodEssenceExtract()
{
ChatMessage chatMessage = new ChatMessage(null, ChatMessageType.GAMEMESSAGE, "", EXTRACT_BLOOD_ESSENCE, "", 0);
when(configManager.getConfiguration(ItemChargeConfig.GROUP, ItemChargeConfig.KEY_BLOOD_ESSENCE, Integer.class)).thenReturn(1000);
itemChargePlugin.onChatMessage(chatMessage);
verify(configManager).setRSProfileConfiguration(ItemChargeConfig.GROUP, ItemChargeConfig.KEY_BLOOD_ESSENCE, 933);
}
@Test
public void testBloodEssenceCheck()
{
ChatMessage chatMessage = new ChatMessage(null, ChatMessageType.GAMEMESSAGE, "", CHECK_BLOOD_ESSENCE, "", 0);
itemChargePlugin.onChatMessage(chatMessage);
verify(configManager).setRSProfileConfiguration(ItemChargeConfig.GROUP, ItemChargeConfig.KEY_BLOOD_ESSENCE, 56);
}
}