Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ baseGroup=com.jelly.farmhelperv2
mcVersion=1.8.9
modid=farmhelperv2
modName=FarmHelper
version=2.9.1-pre1
version=2.9.1-pre2
shouldRelease=true
Original file line number Diff line number Diff line change
Expand Up @@ -1295,7 +1295,17 @@ public static void triggerManuallyPestsDestroyer() {
//</editor-fold>

//<editor-fold desc="Drawings">


@Color(
name = "Rewarp Color", category = GENERAL, subcategory = "Rewarp",
description = "The color of the rewarp box"
)
public static OneColor rewarpColor = new OneColor(0, 255, 217, 171);
@Color(
name = "Spawn Color", category = GENERAL, subcategory = "Spawn Position",
description = "The color of the spawn box"
)
public static OneColor spawnColor = new OneColor(0, 255, 217, 171);
@Switch(
name = "Pests ESP", category = PESTS_DESTROYER, subcategory = "Drawings",
description = "Draws a box around pests"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -357,22 +357,21 @@ public void onRenderWorldLast(RenderWorldLastEvent event) {
if (FarmHelperConfig.streamerMode) return;

if (FarmHelperConfig.highlightRewarp && FarmHelperConfig.rewarpList != null && GameStateHandler.getInstance().inGarden()) {
Color chroma = Color.getHSBColor((float) ((System.currentTimeMillis() / 10) % 2000) / 2000, 1, 1);

for (Rewarp rewarp : FarmHelperConfig.rewarpList) {
double distance = mc.thePlayer.getDistance(rewarp.x, rewarp.y, rewarp.z);
Color chromaLowerAlpha = new Color(chroma.getRed(), chroma.getGreen(), chroma.getBlue(), Math.max(0, 120 - (int) (distance * 2)));
Color rewarpColor = FarmHelperConfig.rewarpColor.toJavaColor();
if (distance < 50) {
RenderUtils.drawBlockBox(new BlockPos(rewarp.x, rewarp.y, rewarp.z), chromaLowerAlpha);
RenderUtils.drawBlockBox(new BlockPos(rewarp.x, rewarp.y, rewarp.z), rewarpColor);
}
}
}

if (FarmHelperConfig.drawSpawnLocation && PlayerUtils.isSpawnLocationSet() && GameStateHandler.getInstance().inGarden()) {
BlockPos spawnLocation = new BlockPos(PlayerUtils.getSpawnLocation());
double distance = mc.thePlayer.getDistance(spawnLocation.getX(), spawnLocation.getY(), spawnLocation.getZ());
Color spawnColor = FarmHelperConfig.spawnColor.toJavaColor();
if (distance < 50) {
RenderUtils.drawBlockBox(spawnLocation, new Color(Color.orange.getRed(), Color.orange.getGreen(), Color.orange.getBlue(), Math.max(0, 80 - (int) (distance * 1.6))));
RenderUtils.drawBlockBox(spawnLocation, spawnColor);
}
}

Expand Down