Skip to content

Commit

Permalink
Feature: Custom Inquisitor Highlight Color (#1323)
Browse files Browse the repository at this point in the history
  • Loading branch information
ItsEmpa authored Apr 1, 2024
1 parent 6ac1fba commit 9d0f4de
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import com.google.gson.annotations.Expose;
import io.github.moulberry.moulconfig.annotations.Accordion;
import io.github.moulberry.moulconfig.annotations.ConfigEditorBoolean;
import io.github.moulberry.moulconfig.annotations.ConfigEditorColour;
import io.github.moulberry.moulconfig.annotations.ConfigEditorKeybind;
import io.github.moulberry.moulconfig.annotations.ConfigOption;
import org.lwjgl.input.Keyboard;
Expand All @@ -16,6 +17,11 @@ public class DianaConfig {
@FeatureToggle
public boolean highlightInquisitors = true;

@Expose
@ConfigOption(name = "Inquisitor Highlight", desc = "Color in which Inquisitors will be highlighted.")
@ConfigEditorColour
public String color = "0:127:85:255:255";

@Expose
@ConfigOption(name = "Guess Next Burrow", desc = "Uses math from §eSoopy's Guess Logic §7to find the next burrow. Does not require SoopyV2 or ChatTriggers to be installed.")
@ConfigEditorBoolean
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@ package at.hannibal2.skyhanni.features.event.diana

import at.hannibal2.skyhanni.SkyHanniMod
import at.hannibal2.skyhanni.mixins.hooks.RenderLivingEntityHelper
import at.hannibal2.skyhanni.utils.ColorUtils.withAlpha
import at.hannibal2.skyhanni.utils.LorenzColor
import at.hannibal2.skyhanni.utils.LorenzUtils
import at.hannibal2.skyhanni.utils.SpecialColour
import net.minecraft.entity.player.EntityPlayer
import net.minecraftforge.event.entity.EntityJoinWorldEvent
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
Expand All @@ -21,7 +20,7 @@ class HighlightInquisitors {
val entity = event.entity

if (entity is EntityPlayer && entity.name == "Minos Inquisitor") {
val color = LorenzColor.AQUA.toColor().withAlpha(127)
val color = SpecialColour.specialToChromaRGB(config.color)
RenderLivingEntityHelper.setEntityColorWithNoHurtTime(entity, color) { config.highlightInquisitors }
}
}
Expand Down

0 comments on commit 9d0f4de

Please sign in to comment.