Skip to content

Commit

Permalink
check if on hypixel before canceling bossbar
Browse files Browse the repository at this point in the history
  • Loading branch information
MicrocontrollersDev authored Jun 22, 2024
1 parent 60043c0 commit 3fea312
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public abstract class BossStatusMixin_HideBossbar {
@Inject(method = "setBossStatus", at = @At("HEAD"), cancellable = true)
private static void hytils$cancelBossStatus(IBossDisplayData displayData, boolean hasColorModifierIn, CallbackInfo ci) {
if (displayData == null) return;
if (HytilsConfig.lobbyBossbar && !LocrawUtil.INSTANCE.isInGame() || HytilsConfig.gameAdBossbar && displayData.getDisplayName().getFormattedText().matches(HytilsReborn.INSTANCE.getLanguageHandler().getCurrent().gameBossbarAdvertisementRegex.pattern()))
if (HytilsConfig.lobbyBossbar && HypixelUtils.INSTANCE.isHypixel() && !LocrawUtil.INSTANCE.isInGame() || HytilsConfig.gameAdBossbar && displayData.getDisplayName().getFormattedText().matches(HytilsReborn.INSTANCE.getLanguageHandler().getCurrent().gameBossbarAdvertisementRegex.pattern()))
ci.cancel();
}
}

0 comments on commit 3fea312

Please sign in to comment.