-
-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Slayer System rework #1040
base: master
Are you sure you want to change the base?
Slayer System rework #1040
Conversation
7azeemm
commented
Nov 1, 2024
- Added Slayer HUD
- Added Boss slain time
- Added Personal Best slain time
- Added Boss and MiniBoss spawn alert
- Added Mute Enderman sounds
- Added Lazer phase Timer
Added Boss slain time Added Personal Best slain time Added Boss and MiniBoss spawn alert Added Mute Enderman sounds Added Lazer phase Timer
Looks pretty good. |
nice, appreciate your help |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few nitpicks here and there but the code looks good in general. I didn't look too deep into the logic since stuff just seemed to work, excluding the LazerTimer as I wasn't able to test it. (too weak for voidgloom seraph lol)
src/main/java/de/hysky/skyblocker/skyblock/slayers/SlayerManager.java
Outdated
Show resolved
Hide resolved
src/main/java/de/hysky/skyblocker/skyblock/slayers/SlayerManager.java
Outdated
Show resolved
Hide resolved
src/main/java/de/hysky/skyblocker/skyblock/slayers/SlayerManager.java
Outdated
Show resolved
Hide resolved
src/main/java/de/hysky/skyblocker/skyblock/slayers/SlayerManager.java
Outdated
Show resolved
Hide resolved
|
||
@Init | ||
public static void init() { | ||
actions.put(SlayerAction.CANCELLED, () -> quest = null); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This actions system could be converted to use actual methods and call those methods depending on the actual string value of the matched group from the regex.
While this might be a shorter way to do the same thing, it's not quite obvious from first look what it is for, and adds unnecessary complexity.
src/main/java/de/hysky/skyblocker/skyblock/slayers/hud/SlayerHudWidget.java
Outdated
Show resolved
Hide resolved
public static int calculateBossesNeeded() { | ||
int tier = RomanNumerals.romanToDecimal(slayerTier); | ||
if (tier == 0) return -1; | ||
|
||
int xpPerTier; | ||
if (slayerType.equals("Vampire")) { | ||
xpPerTier = SlayerConstants.vampireXpPerTier[tier - 1]; | ||
} else { | ||
xpPerTier = SlayerConstants.regularXpPerTier[tier - 1]; | ||
} | ||
|
||
return (int) Math.ceil((double) xpRemaining / xpPerTier); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This method doesn't account for the xp bonus of Aatrox mayor/minister.
private static final Logger LOGGER = LoggerFactory.getLogger(SlayerManager.class); | ||
private static final Map<SlayerAction, Runnable> actions = new HashMap<>(); | ||
private static final Pattern SLAYER_PATTERN = Pattern.compile("Revenant Horror|Tarantula Broodfather|Sven Packmaster|Voidgloom Seraph|Inferno Demonlord|Riftstalker Bloodfiend"); | ||
private static final Pattern SLAYER_TIER_PATTERN = Pattern.compile("^(Revenant Horror|Tarantula Broodfather|Sven Packmaster|Voidgloom Seraph|Inferno Demonlord|Riftstalker Bloodfiend)\\s+(I|II|III|IV|V)$"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hypixel decided to make the Riftstalker Bloodfiend break the pattern. It's in game nametag does not contain its full name. I know this is an existing bug but it'd be great if u could fix it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a complete review yet, but just some comments.
src/main/java/de/hysky/skyblocker/mixins/WorldRendererMixin.java
Outdated
Show resolved
Hide resolved
src/main/java/de/hysky/skyblocker/mixins/WorldRendererMixin.java
Outdated
Show resolved
Hide resolved
src/main/java/de/hysky/skyblocker/mixins/WorldRendererMixin.java
Outdated
Show resolved
Hide resolved
Co-authored-by: Kevin <92656833+kevinthegreat1@users.noreply.github.com>
mixins changes shows now previous personalBest and more