Lambda fixes & removed crosshair

This commit is contained in:
ThisIsALegitUsername 2023-02-11 21:25:12 +00:00
parent f4957201f6
commit 8a539233ac
4 changed files with 3 additions and 30 deletions

View File

@ -8,7 +8,7 @@ public class Resent {
INSTANCE = new Resent();
}
public static final String NAME = "Resent", VERSION = "3.4";
public static final String NAME = "Resent", VERSION = "3.5";
public static final Resent INSTANCE;
//private ISound uwu;
public ModManager modManager;

View File

@ -21,7 +21,6 @@ import dev.resent.module.impl.misc.AutoGG;
import dev.resent.module.impl.misc.AutoRespawn;
import dev.resent.module.impl.misc.ClearChat;
import dev.resent.module.impl.misc.Cosmetics;
import dev.resent.module.impl.misc.Crosshair;
import dev.resent.module.impl.misc.CrystalOptimizer;
import dev.resent.module.impl.misc.DynamicFOV;
import dev.resent.module.impl.misc.FPSB;
@ -63,7 +62,6 @@ public class ModManager {
public static MinimalViewBobbing minimalViewBobbing = new MinimalViewBobbing();
public static NoSwingDelay noSwingDelay;
public static PotCounter potCounter;
public static Crosshair crosshair = new Crosshair();
public static HUD hud = new HUD();
public static CrystalOptimizer crystalOptimizer = new CrystalOptimizer();
public static TabGui tabGui = new TabGui();
@ -87,7 +85,6 @@ public class ModManager {
register(potCounter = new PotCounter());
//Mechanic
register(crosshair);
register(autoRespawn = new AutoRespawn());
register(fullbright = new Fullbright());
register(noSwingDelay = new NoSwingDelay());

View File

@ -1,14 +0,0 @@
package dev.resent.module.impl.misc;
import dev.resent.annotation.Module;
import dev.resent.module.base.Mod.Category;
import dev.resent.module.base.Mod;
import dev.resent.module.setting.ModeSetting;
@Module(name = "Crosshair", category = Category.MISC, hasSetting = true)
public class Crosshair extends Mod {
public Crosshair() { addSetting(color); }
public static ModeSetting color = new ModeSetting("Hovered crosshair color", "", "White", "Red", "Yellow", "Green", "Blue", "Black");
}

View File

@ -14,15 +14,10 @@ import com.google.common.collect.Iterables;
import com.google.common.collect.Lists;
import dev.resent.Resent;
import dev.resent.ui.animation.SimpleAnimation;
import dev.resent.module.base.Mod;
import dev.resent.module.base.ModManager;
import dev.resent.module.base.RenderMod;
import dev.resent.module.impl.misc.Crosshair;
import dev.resent.ui.HUDConfigScreen;
import dev.resent.ui.animation.SimpleAnimation;
import dev.resent.util.misc.W;
import dev.resent.util.render.Color;
import dev.resent.util.render.RenderUtils;
import net.lax1dude.eaglercraft.v1_8.EaglercraftRandom;
import net.lax1dude.eaglercraft.v1_8.minecraft.EaglerTextureAtlasSprite;
import net.lax1dude.eaglercraft.v1_8.opengl.GlStateManager;
@ -316,7 +311,7 @@ public class GuiIngame extends Gui {
this.overlayPlayerList.renderPlayerlist(i, scoreboard, scoreobjective1);
}
Resent.INSTANCE.modManager.modules.stream().filter(m -> m.isEnabled()).filter(RenderMod.class::isInstance).forEach(m -> ((RenderMod)m).draw());
Resent.INSTANCE.modManager.modules.stream().filter(m -> m.isEnabled() && m instanceof RenderMod).forEach(m -> ((RenderMod)m).draw());
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
GlStateManager.disableLighting();
@ -330,11 +325,6 @@ public class GuiIngame extends Gui {
GlStateManager.enableBlend();
GlStateManager.tryBlendFuncSeparate(GL_ONE_MINUS_DST_COLOR, GL_ONE_MINUS_SRC_COLOR, 1, 0);
GlStateManager.enableAlpha();
if (ModManager.crosshair.isEnabled() && Minecraft.getMinecraft().pointedEntity != null){
GlStateManager.color(RenderUtils.getColorWithoutRGB(Crosshair.color).getRed(), RenderUtils.getColorWithoutRGB(Crosshair.color).getGreen(), RenderUtils.getColorWithoutRGB(Crosshair.color).getBlue(), 255);
GlStateManager.disableAlpha();
}
this.drawTexturedModalRect(scaledResWidth / 2 - 7, scaledResHeight / 2 - 7, 0, 0, 16, 16);
}