diff options
| author | Walker Selby <git@walkerselby.com> | 2022-03-27 12:13:08 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-03-27 13:13:08 -0400 |
| commit | 5e7a8a02fe836c1e635faf067fbe8913549bc0e0 (patch) | |
| tree | dc99a2544bd81af6d70c7bd07ba53142ff38d057 /src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java | |
| parent | 47efdd4f84cc9a29738fe16d631eb33ee716db61 (diff) | |
| download | notenoughupdates-5e7a8a02fe836c1e635faf067fbe8913549bc0e0.tar.gz notenoughupdates-5e7a8a02fe836c1e635faf067fbe8913549bc0e0.tar.bz2 notenoughupdates-5e7a8a02fe836c1e635faf067fbe8913549bc0e0.zip | |
Add NBT Data to Profile Viewer Tabs and XP Bars (#94)
* Fixed what hypxiel broke in dungeons
* Added Longswords to Tools Tab (Itemlist)
* Set max cata level to 70
* ups
* why is it now E
* YEP the cap is 99 not 70
* long cata xp BatChest + remove crash check because hypixel profile is null and i havent fixed that yet
* Added checks for chat messages for dungeon win overlay - i think ive got them all but 4Shrug
* Added an option to alert you if you put something for too much onto ah (default 50%) + Lowest bin alert triggers if lowest bin isnt found
* IMPORTANT
* fix dungeon page in /pv
* show minions from coop in /pv
* (BREAKING CHANGE) remove whitespace in changelog
* fix crash with minion check
* initial draft
* tooltip
* important changes
* progress related things
progress bar for community goals
total collected points and personal goals display
* only show bingo tab on Bingo profiles
* make goals display gold when completed
* Added MM7 button to dungeon preset
* wart go not stonks
* fix percents and added stack size
* use code nopo in fortnite shop — Today at 17:29
The capitalisation
* config option for always showing bingo page
* 🙂
* movble pv tabs
* 2.1.md 🙂
* oops
* der Kabel
* import
* Added powder amount to level up perk
* Made it only show if the perk isnt maxed / level 0
* fix /pv crash when pet is not in repo
* 2.1.md 🙂
* web editor my beloved
* Add NBT Data to Profile Viewer Tabs and XP Bars
Add NBT Data Support for Resources in Tabs
Add NBT Data Support for Resources in XP Bars
Optimize renderTabs function
Optimize mouseClicked Function
Optimize ProfileViewerPage Enum
* Update Style
Co-authored-by: NopoTheGamer <40329022+NopoTheGamer@users.noreply.github.com>
* Update GuiProfileViewer
Rebased on pvbingo
Updated formatting with IntelliJ reformatting tool (hopefully that matches now, let me know if you want me to try again but I think I did it right)
* dungeons and pv bingo tab (#93)
* add custom skull loading back (#96)
* Refactor Hollows solvers, add tests, add Vec3Comparable, fix bugs (#95)
* Rebase on master
* Fix conflicts and rebase on master
Add changes to change log
* Oops
Co-authored-by: nopo <noahogno@gmail.com>
Co-authored-by: jani270 <jani270@gmx.de>
Co-authored-by: Lulonaut <lulonaut@tutanota.de>
Co-authored-by: NopoTheGamer <40329022+NopoTheGamer@users.noreply.github.com>
Co-authored-by: Lulonaut <67191924+Lulonaut@users.noreply.github.com>
Co-authored-by: CraftyOldMiner <85420839+CraftyOldMiner@users.noreply.github.com>
Diffstat (limited to 'src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java')
| -rw-r--r-- | src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java | 148 |
1 files changed, 88 insertions, 60 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java b/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java index 951e7335..0ed68e06 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java @@ -1,5 +1,17 @@ package io.github.moulberry.notenoughupdates; +import java.awt.Color; +import java.io.BufferedReader; +import java.io.BufferedWriter; +import java.io.File; +import java.io.FileInputStream; +import java.io.FileOutputStream; +import java.io.InputStreamReader; +import java.io.OutputStreamWriter; +import java.nio.charset.StandardCharsets; +import java.util.HashMap; +import java.util.Set; + import com.google.common.collect.Sets; import com.google.gson.Gson; import com.google.gson.GsonBuilder; @@ -12,9 +24,22 @@ import io.github.moulberry.notenoughupdates.listener.ChatListener; import io.github.moulberry.notenoughupdates.listener.ItemTooltipListener; import io.github.moulberry.notenoughupdates.listener.NEUEventListener; import io.github.moulberry.notenoughupdates.listener.RenderListener; -import io.github.moulberry.notenoughupdates.miscfeatures.*; +import io.github.moulberry.notenoughupdates.miscfeatures.CrystalOverlay; +import io.github.moulberry.notenoughupdates.miscfeatures.CrystalWishingCompassSolver; +import io.github.moulberry.notenoughupdates.miscfeatures.CustomItemEffects; +import io.github.moulberry.notenoughupdates.miscfeatures.DwarvenMinesWaypoints; +import io.github.moulberry.notenoughupdates.miscfeatures.EnchantingSolvers; +import io.github.moulberry.notenoughupdates.miscfeatures.FairySouls; +import io.github.moulberry.notenoughupdates.miscfeatures.FishingHelper; +import io.github.moulberry.notenoughupdates.miscfeatures.ItemCooldowns; +import io.github.moulberry.notenoughupdates.miscfeatures.ItemCustomizeManager; +import io.github.moulberry.notenoughupdates.miscfeatures.MiningStuff; +import io.github.moulberry.notenoughupdates.miscfeatures.NullzeeSphere; +import io.github.moulberry.notenoughupdates.miscfeatures.PetInfoOverlay; +import io.github.moulberry.notenoughupdates.miscfeatures.SlotLocking; +import io.github.moulberry.notenoughupdates.miscfeatures.StorageManager; +import io.github.moulberry.notenoughupdates.miscfeatures.SunTzu; import io.github.moulberry.notenoughupdates.miscfeatures.customblockzones.CustomBiomes; -import io.github.moulberry.notenoughupdates.miscfeatures.customblockzones.CustomBlockSounds; import io.github.moulberry.notenoughupdates.miscfeatures.customblockzones.DwarvenMinesTextures; import io.github.moulberry.notenoughupdates.miscgui.CalendarOverlay; import io.github.moulberry.notenoughupdates.miscgui.InventoryStorageSelector; @@ -28,14 +53,17 @@ import io.github.moulberry.notenoughupdates.util.Utils; import io.github.moulberry.notenoughupdates.util.XPInformation; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiScreen; -import net.minecraft.client.resources.IReloadableResourceManager; import net.minecraft.client.settings.KeyBinding; import net.minecraft.event.ClickEvent; import net.minecraft.scoreboard.ScoreObjective; import net.minecraft.scoreboard.Scoreboard; import net.minecraft.util.ChatComponentText; import net.minecraft.util.EnumChatFormatting; -import net.minecraft.world.biome.*; +import net.minecraft.world.biome.BiomeGenBase; +import net.minecraft.world.biome.BiomeGenHell; +import net.minecraft.world.biome.BiomeGenJungle; +import net.minecraft.world.biome.BiomeGenMesa; +import net.minecraft.world.biome.BiomeGenSnow; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.fml.client.registry.ClientRegistry; import net.minecraftforge.fml.common.Mod; @@ -44,12 +72,6 @@ import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.common.gameevent.TickEvent; -import java.awt.*; -import java.io.*; -import java.nio.charset.StandardCharsets; -import java.util.HashMap; -import java.util.Set; - @Mod(modid = NotEnoughUpdates.MODID, version = NotEnoughUpdates.VERSION, clientSideOnly = true) public class NotEnoughUpdates { public static final String MODID = "notenoughupdates"; @@ -57,6 +79,60 @@ public class NotEnoughUpdates { public static final String PRE_VERSION = "0.0"; public static final int VERSION_ID = 20100; public static final int PRE_VERSION_ID = 0; + + public static NotEnoughUpdates INSTANCE = null; + + public NEUManager manager; + public NEUOverlay overlay; + public NEUConfig config; + + private File configFile; + + public File getConfigFile() { + return this.configFile; + } + + public void newConfigFile() { + this.configFile = new File(NotEnoughUpdates.INSTANCE.getNeuDir(), "configNew.json"); + } + + private static final long CHAT_MSG_COOLDOWN = 200; + private long lastChatMessage = 0; + private long secondLastChatMessage = 0; + private String currChatMessage = null; + + //Stolen from Biscut and used for detecting whether in skyblock + private static final Set<String> SKYBLOCK_IN_ALL_LANGUAGES = + Sets.newHashSet("SKYBLOCK", "\u7A7A\u5C9B\u751F\u5B58", "\u7A7A\u5CF6\u751F\u5B58"); + + public GuiScreen openGui = null; + public long lastOpenedGui = 0; + + public Commands commands; + + public static HashMap<String, String> petRarityToColourMap = new HashMap<String, String>() {{ + put("UNKNOWN", EnumChatFormatting.RED.toString()); + put("COMMON", EnumChatFormatting.WHITE.toString()); + put("UNCOMMON", EnumChatFormatting.GREEN.toString()); + put("RARE", EnumChatFormatting.BLUE.toString()); + put("EPIC", EnumChatFormatting.DARK_PURPLE.toString()); + put("LEGENDARY", EnumChatFormatting.GOLD.toString()); + put("MYTHIC", EnumChatFormatting.LIGHT_PURPLE.toString()); + }}; + + public static ProfileViewer profileViewer; + + public boolean packDevEnabled = false; + + private final Gson gson = new GsonBuilder().setPrettyPrinting().excludeFieldsWithoutExposeAnnotation().create(); + private File neuDir; + + public File getNeuDir() { + return this.neuDir; + } + + public Color[][] colourMap = null; + /** * Registers the biomes for the crystal hollows here so optifine knows they exists */ @@ -90,48 +166,6 @@ public class NotEnoughUpdates { .setBiomeName("NeuCrystalHollowsCrystalNucleus") .setFillerBlockMetadata(5470985) .setTemperatureRainfall(0.95F, 0.9F); - private static final long CHAT_MSG_COOLDOWN = 200; - //Stolen from Biscut and used for detecting whether in skyblock - private static final Set<String> SKYBLOCK_IN_ALL_LANGUAGES = - Sets.newHashSet("SKYBLOCK", "\u7A7A\u5C9B\u751F\u5B58", "\u7A7A\u5CF6\u751F\u5B58"); - public static NotEnoughUpdates INSTANCE = null; - public static HashMap<String, String> petRarityToColourMap = new HashMap<String, String>() {{ - put("UNKNOWN", EnumChatFormatting.RED.toString()); - put("COMMON", EnumChatFormatting.WHITE.toString()); - put("UNCOMMON", EnumChatFormatting.GREEN.toString()); - put("RARE", EnumChatFormatting.BLUE.toString()); - put("EPIC", EnumChatFormatting.DARK_PURPLE.toString()); - put("LEGENDARY", EnumChatFormatting.GOLD.toString()); - put("MYTHIC", EnumChatFormatting.LIGHT_PURPLE.toString()); - }}; - public static ProfileViewer profileViewer; - private final Gson gson = new GsonBuilder().setPrettyPrinting().excludeFieldsWithoutExposeAnnotation().create(); - public NEUManager manager; - public NEUOverlay overlay; - public NEUConfig config; - public GuiScreen openGui = null; - public long lastOpenedGui = 0; - public Commands commands; - public boolean packDevEnabled = false; - public Color[][] colourMap = null; - private File configFile; - private long lastChatMessage = 0; - private long secondLastChatMessage = 0; - private String currChatMessage = null; - private File neuDir; - private boolean hasSkyblockScoreboard; - - public File getConfigFile() { - return this.configFile; - } - - public void newConfigFile() { - this.configFile = new File(NotEnoughUpdates.INSTANCE.getNeuDir(), "configNew.json"); - } - - public File getNeuDir() { - return this.neuDir; - } /** * Instantiates NEUIo, NEUManager and NEUOverlay instances. Registers keybinds and adds a shutdown hook to clear tmp folder. @@ -215,14 +249,6 @@ public class NotEnoughUpdates { MinecraftForge.EVENT_BUS.register(new CrystalOverlay()); MinecraftForge.EVENT_BUS.register(new ItemCooldowns()); - if (Minecraft.getMinecraft().getResourceManager() instanceof IReloadableResourceManager) { - IReloadableResourceManager manager = (IReloadableResourceManager) Minecraft.getMinecraft().getResourceManager(); - manager.registerReloadListener(CustomSkulls.getInstance()); - manager.registerReloadListener(NPCRetexturing.getInstance()); - manager.registerReloadListener(new ItemCustomizeManager.ReloadListener()); - manager.registerReloadListener(new CustomBlockSounds.ReloaderListener()); - } - this.commands = new Commands(); BackgroundBlur.registerListener(); @@ -384,6 +410,8 @@ public class NotEnoughUpdates { return hasSkyblockScoreboard(); } + private boolean hasSkyblockScoreboard; + public boolean hasSkyblockScoreboard() { return hasSkyblockScoreboard; } |
