Merge remote-tracking branch 'runelite/master'

This commit is contained in:
Owain van Brakel
2022-01-17 22:54:58 +01:00
8 changed files with 669 additions and 677 deletions

View File

@@ -24,10 +24,10 @@
*/
package net.runelite.client.plugins.cluescrolls.clues;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableList;
import java.awt.Color;
import java.awt.Graphics2D;
import java.util.Set;
import java.util.List;
import javax.annotation.Nullable;
import lombok.Getter;
import net.runelite.api.NPC;
@@ -43,7 +43,7 @@ import net.runelite.client.ui.overlay.components.TitleComponent;
@Getter
public class CipherClue extends ClueScroll implements TextClueScroll, NpcClueScroll, LocationClueScroll
{
private static final Set<CipherClue> CLUES = ImmutableSet.of(
private static final List<CipherClue> CLUES = ImmutableList.of(
new CipherClue("BMJ UIF LFCBC TFMMFS", "Ali the Kebab seller", new WorldPoint(3354, 2974, 0), "Pollnivneach", "How many coins would you need to purchase 133 kebabs from me?", "399"),
new CipherClue("GUHCHO", "Drezel", new WorldPoint(3440, 9895, 0), "Paterdomus", "Please solve this for x: 7x - 28=21", "7"),
new CipherClue("HQNM LZM STSNQ", "Iron Man tutor", new WorldPoint(3227, 3227, 0), "Outside Lumbridge castle", "How many snakeskins are needed in order to craft 44 boots, 29 vambraces and 34 bandanas?", "666"),

View File

@@ -24,10 +24,10 @@
*/
package net.runelite.client.plugins.cluescrolls.clues;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableList;
import java.awt.Color;
import java.awt.Graphics2D;
import java.util.Set;
import java.util.List;
import javax.annotation.Nullable;
import lombok.Getter;
import net.runelite.api.NPC;
@@ -51,7 +51,7 @@ import net.runelite.client.ui.overlay.components.TitleComponent;
@Getter
public class CrypticClue extends ClueScroll implements TextClueScroll, NpcClueScroll, ObjectClueScroll
{
public static final Set<CrypticClue> CLUES = ImmutableSet.of(
public static final List<CrypticClue> CLUES = ImmutableList.of(
new CrypticClue("Show this to Sherlock.", "Sherlock", new WorldPoint(2733, 3415, 0), "Sherlock is located to the east of the Sorcerer's tower in Seers' Village."),
new CrypticClue("Talk to the bartender of the Rusty Anchor in Port Sarim.", "Bartender", new WorldPoint(3045, 3256, 0), "The Rusty Anchor is located in the north of Port Sarim."),
new CrypticClue("The keeper of Melzars... Spare? Skeleton? Anar?", "Oziach", new WorldPoint(3068, 3516, 0), "Speak to Oziach in Edgeville."),

View File

@@ -24,11 +24,11 @@
*/
package net.runelite.client.plugins.cluescrolls.clues;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableList;
import java.awt.Color;
import java.awt.Graphics2D;
import java.awt.Polygon;
import java.util.Set;
import java.util.List;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
import lombok.Getter;
@@ -100,7 +100,7 @@ public class EmoteClue extends ClueScroll implements TextClueScroll, LocationClu
item(TZKAL_SLAYER_HELMET_I_25914)
);
private static final Set<EmoteClue> CLUES = ImmutableSet.of(
private static final List<EmoteClue> CLUES = ImmutableList.of(
new EmoteClue("Beckon on the east coast of the Kharazi Jungle. Beware of double agents! Equip any vestment stole and a heraldic rune shield.", "Kharazi Jungle", NORTHEAST_CORNER_OF_THE_KHARAZI_JUNGLE, new WorldPoint(2954, 2933, 0), DOUBLE_AGENT_108, BECKON, any("Any stole", item(GUTHIX_STOLE), item(SARADOMIN_STOLE), item(ZAMORAK_STOLE), item(ARMADYL_STOLE), item(BANDOS_STOLE), item(ANCIENT_STOLE)), any("Any heraldic rune shield", item(RUNE_SHIELD_H1), item(RUNE_SHIELD_H2), item(RUNE_SHIELD_H3), item(RUNE_SHIELD_H4), item(RUNE_SHIELD_H5))),
new EmoteClue("Cheer in the Barbarian Agility Arena. Headbang before you talk to me. Equip a steel platebody, maple shortbow and a Wilderness cape.", "Barbarian Outpost", BARBARIAN_OUTPOST_OBSTACLE_COURSE, new WorldPoint(2552, 3556, 0), CHEER, HEADBANG, item(STEEL_PLATEBODY), item(MAPLE_SHORTBOW), range("Any team cape", TEAM1_CAPE, TEAM50_CAPE)),
new EmoteClue("Bow upstairs in the Edgeville Monastery. Equip a completed prayer book.", "Edgeville Monastery", SOUTHEAST_CORNER_OF_THE_MONASTERY, new WorldPoint(3056, 3484, 1), BOW, any("Any god book", item(HOLY_BOOK), item(BOOK_OF_BALANCE), item(UNHOLY_BOOK), item(BOOK_OF_LAW), item(BOOK_OF_WAR), item(BOOK_OF_DARKNESS))),

View File

@@ -24,10 +24,10 @@
*/
package net.runelite.client.plugins.cluescrolls.clues;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableList;
import java.awt.Color;
import java.awt.Graphics2D;
import java.util.Set;
import java.util.List;
import lombok.Getter;
import net.runelite.api.coords.LocalPoint;
import net.runelite.api.coords.WorldPoint;
@@ -41,7 +41,7 @@ import net.runelite.client.ui.overlay.components.TitleComponent;
@Getter
public class FairyRingClue extends ClueScroll implements TextClueScroll, LocationClueScroll
{
private static final Set<FairyRingClue> CLUES = ImmutableSet.of(
private static final List<FairyRingClue> CLUES = ImmutableList.of(
new FairyRingClue("A I R 2 3 3 1", new WorldPoint(2702, 3246, 0)),
new FairyRingClue("A I Q 0 4 4 0", new WorldPoint(3000, 3110, 0)),
new FairyRingClue("A L P 1 1 4 0", new WorldPoint(2504, 3633, 0)),

View File

@@ -24,10 +24,10 @@
*/
package net.runelite.client.plugins.cluescrolls.clues;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableList;
import java.awt.Color;
import java.awt.Graphics2D;
import java.util.Set;
import java.util.List;
import lombok.Getter;
import static net.runelite.api.ItemID.*;
import net.runelite.api.ObjectComposition;
@@ -58,7 +58,7 @@ public class MapClue extends ClueScroll implements ObjectClueScroll
public static final String WIZARDS_TOWER_DIS = "On the south side of the Wizard's Tower (DIS)";
public static final String SOUTH_OF_DRAYNOR_BANK = "South of Draynor Village Bank";
private static final Set<MapClue> CLUES = ImmutableSet.of(
private static final List<MapClue> CLUES = ImmutableList.of(
new MapClue(CLUE_SCROLL_EASY_12179, new WorldPoint(3300, 3291, 0), "Al Kharid mine"),
new MapClue(CLUE_SCROLL_EASY_2713, new WorldPoint(3166, 3361, 0), CHAMPIONS_GUILD),
new MapClue(CLUE_SCROLL_EASY_2716, new WorldPoint(3290, 3374, 0), VARROCK_EAST_MINE),

View File

@@ -24,12 +24,11 @@
*/
package net.runelite.client.plugins.cluescrolls.clues;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.ImmutableList;
import java.awt.Color;
import java.awt.Graphics2D;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.Setter;
@@ -129,7 +128,7 @@ public class SkillChallengeClue extends ClueScroll implements NpcClueScroll, Nam
item(ItemID.IMCANDO_HAMMER)
);
private static final Set<SkillChallengeClue> CLUES = ImmutableSet.of(
private static final List<SkillChallengeClue> CLUES = ImmutableList.of(
// Charlie Tasks
new SkillChallengeClue("Cook a Pike", "i need to cook charlie a pike.", "i need to take the cooked pike to charlie.", item(ItemID.PIKE), item(ItemID.RAW_PIKE)),
new SkillChallengeClue("Cook a Trout", "i need to cook charlie a trout.", "i need to take the cooked trout to charlie.", item(ItemID.TROUT), item(ItemID.RAW_TROUT)),

View File

@@ -233,8 +233,10 @@ public class DiscordPlugin extends Plugin
return;
}
CharMatcher matcher = CharMatcher.anyOf("abcdef0123456789");
if (!matcher.matchesAllOf(event.getUserId()) || !matcher.matchesAllOf(event.getAvatarId()))
final CharMatcher matcher = CharMatcher.anyOf("abcdef0123456789");
// animated avatars contain a_ as prefix so we need to get rid of that first to check against matcher
if (!matcher.matchesAllOf(event.getUserId()) || !matcher.matchesAllOf(event.getAvatarId().replace("a_", "")))
{
// userid is actually a snowflake, but the matcher is sufficient
return;