From 50dc2122462642a0c3a00b3a3ae6389825dc04df Mon Sep 17 00:00:00 2001
From: IRONM00N <64110067+IRONM00N@users.noreply.github.com>
Date: Thu, 9 Jun 2022 18:04:22 -0400
Subject: Re-license project as LGPL (#157)
* add licence files & a few misc chores
* add license notices & run auto formatter
---
.../moulberry/notenoughupdates/CustomItems.java | 19 +
.../notenoughupdates/ItemPriceInformation.java | 20 +-
.../github/moulberry/notenoughupdates/NEUApi.java | 20 +-
.../moulberry/notenoughupdates/NEUManager.java | 19 +
.../moulberry/notenoughupdates/NEUOverlay.java | 19 +
.../notenoughupdates/NEURepoResourcePack.java | 126 +++---
.../notenoughupdates/NotEnoughUpdates.java | 19 +
.../notenoughupdates/auction/APIManager.java | 32 +-
.../notenoughupdates/auction/CustomAH.java | 19 +
.../notenoughupdates/auction/CustomAHGui.java | 19 +
.../commands/ClientCommandBase.java | 19 +
.../notenoughupdates/commands/Commands.java | 34 +-
.../commands/EntityViewerCommand.java | 121 +++---
.../notenoughupdates/commands/ScreenCommand.java | 19 +
.../commands/dev/DevTestCommand.java | 19 +
.../notenoughupdates/commands/dev/DiagCommand.java | 22 +-
.../commands/dev/DungeonWinTestCommand.java | 19 +
.../commands/dev/NullzeeSphereCommand.java | 19 +
.../commands/dev/PackDevCommand.java | 87 ++--
.../commands/dev/ReloadRepoCommand.java | 19 +
.../commands/dev/ResetRepoCommand.java | 19 +
.../commands/dev/StatsCommand.java | 19 +
.../commands/dungeon/DhCommand.java | 19 +
.../commands/dungeon/DnCommand.java | 19 +
.../commands/dungeon/JoinDungeonCommand.java | 19 +
.../commands/dungeon/MapCommand.java | 19 +
.../commands/help/FeaturesCommand.java | 19 +
.../commands/help/HelpCommand.java | 21 +-
.../commands/help/LinksCommand.java | 19 +
.../commands/help/SettingsCommand.java | 19 +
.../commands/help/StorageViewerWhyCommand.java | 19 +
.../notenoughupdates/commands/misc/AhCommand.java | 19 +
.../commands/misc/ButtonsCommand.java | 19 +
.../commands/misc/CalendarCommand.java | 19 +
.../commands/misc/CosmeticsCommand.java | 19 +
.../commands/misc/CustomizeCommand.java | 20 +-
.../commands/profile/CataCommand.java | 19 +
.../commands/profile/PeekCommand.java | 19 +
.../commands/profile/PvCommand.java | 19 +
.../commands/profile/ViewProfileCommand.java | 19 +
.../notenoughupdates/core/BackgroundBlur.java | 19 +
.../notenoughupdates/core/ChromaColour.java | 19 +
.../notenoughupdates/core/GlScissorStack.java | 19 +
.../notenoughupdates/core/GuiElement.java | 19 +
.../notenoughupdates/core/GuiElementBoolean.java | 19 +
.../notenoughupdates/core/GuiElementColour.java | 19 +
.../notenoughupdates/core/GuiElementTextField.java | 19 +
.../core/GuiScreenElementWrapper.java | 19 +
.../notenoughupdates/core/config/Config.java | 19 +
.../core/config/GuiPositionEditor.java | 19 +
.../core/config/KeybindHelper.java | 19 +
.../notenoughupdates/core/config/Position.java | 19 +
.../notenoughupdates/core/config/PositionNew.java | 19 +
.../core/config/annotations/Category.java | 19 +
.../core/config/annotations/ConfigAccordionId.java | 19 +
.../config/annotations/ConfigEditorAccordion.java | 19 +
.../config/annotations/ConfigEditorBoolean.java | 19 +
.../config/annotations/ConfigEditorButton.java | 19 +
.../config/annotations/ConfigEditorColour.java | 19 +
.../annotations/ConfigEditorDraggableList.java | 20 +
.../config/annotations/ConfigEditorDropdown.java | 19 +
.../core/config/annotations/ConfigEditorFSR.java | 19 +
.../config/annotations/ConfigEditorKeybind.java | 19 +
.../config/annotations/ConfigEditorSlider.java | 19 +
.../core/config/annotations/ConfigEditorText.java | 19 +
.../core/config/annotations/ConfigOption.java | 19 +
.../core/config/gui/GuiOptionEditor.java | 19 +
.../core/config/gui/GuiOptionEditorAccordion.java | 19 +
.../core/config/gui/GuiOptionEditorBoolean.java | 21 +-
.../core/config/gui/GuiOptionEditorButton.java | 19 +
.../core/config/gui/GuiOptionEditorColour.java | 19 +
.../config/gui/GuiOptionEditorDraggableList.java | 19 +
.../core/config/gui/GuiOptionEditorDropdown.java | 19 +
.../core/config/gui/GuiOptionEditorFSR.java | 19 +
.../core/config/gui/GuiOptionEditorKeybind.java | 19 +
.../core/config/gui/GuiOptionEditorSlider.java | 19 +
.../core/config/gui/GuiOptionEditorText.java | 19 +
.../core/config/gui/GuiPositionEditor.java | 19 +
.../core/config/struct/ConfigProcessor.java | 51 ++-
.../core/util/GuiElementSlider.java | 27 +-
.../moulberry/notenoughupdates/core/util/Line.java | 53 ++-
.../notenoughupdates/core/util/MiscUtils.java | 19 +
.../notenoughupdates/core/util/Splitters.java | 19 +
.../notenoughupdates/core/util/StringUtils.java | 19 +
.../notenoughupdates/core/util/Vec3Comparable.java | 37 +-
.../notenoughupdates/core/util/lerp/LerpUtils.java | 19 +
.../core/util/lerp/LerpingFloat.java | 19 +
.../core/util/lerp/LerpingInteger.java | 19 +
.../core/util/render/RenderUtils.java | 19 +
.../core/util/render/TextRenderUtils.java | 19 +
.../notenoughupdates/cosmetics/CapeManager.java | 19 +
.../notenoughupdates/cosmetics/CapeNode.java | 21 +-
.../notenoughupdates/cosmetics/GuiCosmetics.java | 19 +
.../notenoughupdates/cosmetics/NEUCape.java | 19 +
.../notenoughupdates/cosmetics/ShaderManager.java | 19 +
.../notenoughupdates/dungeons/DungeonBlocks.java | 19 +
.../notenoughupdates/dungeons/DungeonMap.java | 26 +-
.../notenoughupdates/dungeons/DungeonWin.java | 37 +-
.../dungeons/GuiDungeonMapEditor.java | 29 +-
.../notenoughupdates/events/NEUEvent.java | 19 +
.../events/OnBlockBreakSoundEffect.java | 20 +-
.../events/RepositoryReloadEvent.java | 19 +
.../notenoughupdates/infopanes/DevInfoPane.java | 19 +
.../infopanes/FlipperInfoPane.java | 19 +
.../notenoughupdates/infopanes/HTMLInfoPane.java | 30 +-
.../notenoughupdates/infopanes/InfoPane.java | 19 +
.../infopanes/ScrollableInfoPane.java | 19 +
.../notenoughupdates/infopanes/TextInfoPane.java | 19 +
.../notenoughupdates/itemeditor/GuiElement.java | 19 +
.../itemeditor/GuiElementButton.java | 19 +
.../itemeditor/GuiElementText.java | 19 +
.../itemeditor/GuiElementTextField.java | 19 +
.../notenoughupdates/itemeditor/NEUItemEditor.java | 19 +
.../notenoughupdates/listener/ChatListener.java | 35 +-
.../listener/ItemTooltipListener.java | 20 +-
.../listener/NEUEventListener.java | 19 +
.../listener/OldAnimationChecker.java | 19 +
.../notenoughupdates/listener/RenderListener.java | 31 +-
.../listener/ScoreboardLocationChangeListener.java | 19 +
.../notenoughupdates/mbgui/MBAnchorPoint.java | 19 +
.../notenoughupdates/mbgui/MBDeserializer.java | 19 +
.../notenoughupdates/mbgui/MBGuiElement.java | 19 +
.../notenoughupdates/mbgui/MBGuiGroup.java | 19 +
.../notenoughupdates/mbgui/MBGuiGroupAligned.java | 19 +
.../notenoughupdates/mbgui/MBGuiGroupFloating.java | 25 +-
.../miscfeatures/AuctionBINWarning.java | 19 +
.../miscfeatures/AuctionSortModeWarning.java | 24 +-
.../miscfeatures/BetterContainers.java | 19 +
.../miscfeatures/CookieWarning.java | 54 ++-
.../miscfeatures/CrystalMetalDetectorSolver.java | 136 +++---
.../miscfeatures/CrystalOverlay.java | 19 +
.../miscfeatures/CrystalWishingCompassSolver.java | 254 ++++++-----
.../miscfeatures/CustomItemEffects.java | 41 +-
.../miscfeatures/CustomSkulls.java | 38 +-
.../miscfeatures/DamageCommas.java | 19 +
.../miscfeatures/DwarvenMinesWaypoints.java | 19 +
.../miscfeatures/EnchantingSolvers.java | 25 +-
.../notenoughupdates/miscfeatures/FairySouls.java | 33 +-
.../miscfeatures/FishingHelper.java | 19 +
.../miscfeatures/ItemCooldowns.java | 19 +
.../miscfeatures/ItemCustomizeManager.java | 27 +-
.../miscfeatures/ItemRarityHalo.java | 25 +-
.../notenoughupdates/miscfeatures/MiningStuff.java | 19 +
.../miscfeatures/NPCRetexturing.java | 19 +
.../notenoughupdates/miscfeatures/Navigation.java | 19 +
.../miscfeatures/NullzeeSphere.java | 19 +
.../miscfeatures/PetInfoOverlay.java | 19 +
.../notenoughupdates/miscfeatures/SlotLocking.java | 35 +-
.../miscfeatures/StorageManager.java | 53 ++-
.../miscfeatures/StreamerMode.java | 19 +
.../notenoughupdates/miscfeatures/SunTzu.java | 19 +
.../customblockzones/CrystalHollowsTextures.java | 19 +
.../customblockzones/CustomBiomes.java | 19 +
.../customblockzones/CustomBlockSounds.java | 20 +-
.../customblockzones/DwarvenMinesTextures.java | 19 +
.../customblockzones/IslandZoneSubdivider.java | 19 +
.../customblockzones/LocationChangeEvent.java | 19 +
.../customblockzones/SpecialBlockZone.java | 19 +
.../miscfeatures/entityviewer/AgeModifier.java | 55 ++-
.../miscfeatures/entityviewer/ChargedModifier.java | 35 +-
.../miscfeatures/entityviewer/EntityViewer.java | 366 +++++++++-------
.../entityviewer/EntityViewerModifier.java | 21 +-
.../entityviewer/EquipmentModifier.java | 19 +
.../miscfeatures/entityviewer/GUIClientPlayer.java | 71 +--
.../miscfeatures/entityviewer/HorseModifier.java | 19 +
.../entityviewer/InvisibleModifier.java | 29 +-
.../miscfeatures/entityviewer/NameModifier.java | 19 +
.../miscfeatures/entityviewer/RidingModifier.java | 33 +-
.../miscfeatures/entityviewer/SkinModifier.java | 87 ++--
.../miscfeatures/entityviewer/WitherModifier.java | 61 ++-
.../miscgui/AccessoryBagOverlay.java | 99 +++--
.../notenoughupdates/miscgui/CalendarOverlay.java | 26 +-
.../notenoughupdates/miscgui/GuiCustomEnchant.java | 28 +-
.../notenoughupdates/miscgui/GuiEnchantColour.java | 25 +-
.../miscgui/GuiInvButtonEditor.java | 20 +-
.../notenoughupdates/miscgui/GuiItemCustomize.java | 19 +
.../notenoughupdates/miscgui/GuiItemRecipe.java | 19 +
.../notenoughupdates/miscgui/GuiNavigation.java | 19 +
.../notenoughupdates/miscgui/GuiPriceGraph.java | 50 ++-
.../miscgui/InventoryStorageSelector.java | 19 +
.../notenoughupdates/miscgui/KatSitterOverlay.java | 36 +-
.../miscgui/NEUOverlayPlacements.java | 19 +
.../notenoughupdates/miscgui/StorageOverlay.java | 19 +
.../notenoughupdates/miscgui/TradeWindow.java | 26 +-
.../miscgui/tutorials/NeuConfigTutorial.java | 19 +
.../miscgui/tutorials/NeuTutorial.java | 19 +
.../miscgui/tutorials/TutorialBase.java | 19 +
.../mixins/AccessorEntityAgeable.java | 25 +-
.../mixins/AccessorEntityArmorStand.java | 23 +-
.../mixins/AccessorGuiContainer.java | 47 +-
.../mixins/AccessorGuiEditSign.java | 23 +-
.../mixins/AccessorGuiPlayerTabOverlay.java | 19 +
.../notenoughupdates/mixins/AccessorMinecraft.java | 23 +-
.../mixins/MixinAbstractClientPlayer.java | 19 +
.../notenoughupdates/mixins/MixinContainer.java | 19 +
.../mixins/MixinEffectRenderer.java | 19 +
.../notenoughupdates/mixins/MixinEntity.java | 19 +
.../mixins/MixinEntityAgeable.java | 20 +-
.../notenoughupdates/mixins/MixinEntityHorse.java | 31 +-
.../notenoughupdates/mixins/MixinEntityPlayer.java | 19 +
.../mixins/MixinEntityPlayerSP.java | 19 +
.../mixins/MixinEntityRenderer.java | 19 +
.../mixins/MixinEntitySkeleton.java | 31 +-
.../notenoughupdates/mixins/MixinGuiChest.java | 19 +
.../notenoughupdates/mixins/MixinGuiContainer.java | 26 +-
.../notenoughupdates/mixins/MixinGuiIngame.java | 19 +
.../notenoughupdates/mixins/MixinGuiInventory.java | 19 +
.../notenoughupdates/mixins/MixinGuiScreen.java | 19 +
.../mixins/MixinInventoryEffectRenderer.java | 19 +
.../mixins/MixinInventoryPlayer.java | 19 +
.../mixins/MixinItemCameraTransforms.java | 19 +
.../notenoughupdates/mixins/MixinItemRenderer.java | 19 +
.../notenoughupdates/mixins/MixinItemStack.java | 19 +
.../mixins/MixinLayerArmorBase.java | 19 +
.../mixins/MixinLayerCustomHead.java | 19 +
.../notenoughupdates/mixins/MixinMinecraft.java | 19 +
.../notenoughupdates/mixins/MixinMouseHelper.java | 19 +
.../mixins/MixinNetHandlerPlayClient.java | 37 +-
.../mixins/MixinPlayerControllerMP.java | 19 +
.../notenoughupdates/mixins/MixinRender.java | 19 +
.../notenoughupdates/mixins/MixinRenderFish.java | 21 +-
.../notenoughupdates/mixins/MixinRenderGlobal.java | 19 +
.../notenoughupdates/mixins/MixinRenderItem.java | 19 +
.../notenoughupdates/mixins/MixinRenderList.java | 19 +
.../mixins/MixinRendererLivingEntity.java | 19 +
.../mixins/MixinTextureManager.java | 19 +
.../mixins/MixinTileEntitySkullRenderer.java | 19 +
.../mixins/MixinTileEntitySpecialRenderer.java | 19 +
.../mixins/MixinVboRenderList.java | 19 +
.../notenoughupdates/mixins/MixinWorld.java | 21 +-
.../notenoughupdates/mixins/MixinWorldClient.java | 19 +
.../notenoughupdates/options/NEUConfig.java | 19 +
.../notenoughupdates/options/NEUConfigEditor.java | 19 +
.../options/customtypes/NEUDebugFlag.java | 21 +-
.../options/seperateSections/AHGraph.java | 26 +-
.../options/seperateSections/AHTweaks.java | 25 +-
.../options/seperateSections/AccessoryBag.java | 19 +
.../options/seperateSections/ApiData.java | 19 +
.../options/seperateSections/Calendar.java | 19 +
.../options/seperateSections/CustomArmour.java | 19 +
.../options/seperateSections/DungeonMapConfig.java | 19 +
.../options/seperateSections/Dungeons.java | 29 +-
.../options/seperateSections/Enchanting.java | 25 +-
.../options/seperateSections/Fishing.java | 19 +
.../options/seperateSections/ImprovedSBMenu.java | 19 +
.../options/seperateSections/InventoryButtons.java | 19 +
.../options/seperateSections/ItemOverlays.java | 29 +-
.../options/seperateSections/Itemlist.java | 25 +-
.../options/seperateSections/LocationEdit.java | 24 +-
.../options/seperateSections/Mining.java | 28 +-
.../options/seperateSections/Misc.java | 19 +
.../options/seperateSections/MiscOverlays.java | 35 +-
.../options/seperateSections/NeuAuctionHouse.java | 19 +
.../options/seperateSections/Notifications.java | 19 +
.../options/seperateSections/PetOverlay.java | 25 +-
.../options/seperateSections/ProfileViewer.java | 25 +-
.../options/seperateSections/SkillOverlays.java | 30 +-
.../options/seperateSections/SlayerOverlay.java | 26 +-
.../options/seperateSections/SlotLocking.java | 25 +-
.../options/seperateSections/StorageGUI.java | 29 +-
.../options/seperateSections/Toolbar.java | 27 +-
.../options/seperateSections/TooltipTweaks.java | 19 +
.../options/seperateSections/TradeMenu.java | 19 +
.../overlays/AuctionSearchOverlay.java | 35 +-
.../overlays/BonemerangOverlay.java | 25 +-
.../overlays/CombatSkillOverlay.java | 21 +-
.../overlays/CrystalHollowOverlay.java | 33 +-
.../notenoughupdates/overlays/FarmingOverlay.java | 19 +
.../overlays/FishingSkillOverlay.java | 21 +-
.../notenoughupdates/overlays/FuelBar.java | 19 +
.../notenoughupdates/overlays/MiningOverlay.java | 37 +-
.../overlays/MiningSkillOverlay.java | 21 +-
.../notenoughupdates/overlays/OverlayManager.java | 19 +
.../overlays/RancherBootOverlay.java | 19 +
.../notenoughupdates/overlays/SlayerOverlay.java | 25 +-
.../notenoughupdates/overlays/TextOverlay.java | 19 +
.../overlays/TextOverlayStyle.java | 19 +
.../notenoughupdates/overlays/TimersOverlay.java | 28 +-
.../notenoughupdates/profileviewer/BingoPage.java | 19 +
.../profileviewer/GuiProfileViewer.java | 19 +
.../notenoughupdates/profileviewer/Panorama.java | 20 +-
.../profileviewer/PlayerStats.java | 20 +
.../profileviewer/ProfileViewer.java | 35 +-
.../notenoughupdates/recipes/CraftingOverlay.java | 37 +-
.../notenoughupdates/recipes/CraftingRecipe.java | 282 ++++++------
.../notenoughupdates/recipes/ForgeRecipe.java | 477 ++++++++++++---------
.../notenoughupdates/recipes/Ingredient.java | 21 +-
.../notenoughupdates/recipes/ItemShopRecipe.java | 19 +
.../notenoughupdates/recipes/MobLootRecipe.java | 19 +
.../notenoughupdates/recipes/NeuRecipe.java | 19 +
.../notenoughupdates/recipes/RecipeGenerator.java | 19 +
.../notenoughupdates/recipes/RecipeSlot.java | 19 +
.../notenoughupdates/recipes/RecipeType.java | 19 +
.../recipes/VillagerTradeRecipe.java | 288 +++++++------
.../notenoughupdates/util/AllowEmptyHTMLTag.java | 19 +
.../moulberry/notenoughupdates/util/Constants.java | 19 +
.../moulberry/notenoughupdates/util/Debouncer.java | 19 +
.../util/DiscordMarkdownBuilder.java | 19 +
.../notenoughupdates/util/GuiTextures.java | 19 +
.../notenoughupdates/util/HastebinUploader.java | 19 +
.../notenoughupdates/util/HotmInformation.java | 19 +
.../notenoughupdates/util/HypixelApi.java | 19 +
.../moulberry/notenoughupdates/util/ItemUtils.java | 19 +
.../moulberry/notenoughupdates/util/JsonUtils.java | 19 +
.../notenoughupdates/util/LerpingFloat.java | 19 +
.../notenoughupdates/util/NEUDebugLogger.java | 21 +-
.../notenoughupdates/util/NEUResourceManager.java | 19 +
.../notenoughupdates/util/NotificationHandler.java | 19 +
.../notenoughupdates/util/ProfileApiSyncer.java | 19 +
.../util/RequestFocusListener.java | 19 +
.../util/ReverseWorldRenderer.java | 28 +-
.../moulberry/notenoughupdates/util/SBInfo.java | 30 +-
.../notenoughupdates/util/SkytilsCompat.java | 23 +-
.../notenoughupdates/util/SpecialColour.java | 19 +
.../moulberry/notenoughupdates/util/TexLoc.java | 19 +
.../moulberry/notenoughupdates/util/Utils.java | 19 +
.../notenoughupdates/util/XPInformation.java | 19 +
317 files changed, 7857 insertions(+), 1281 deletions(-)
(limited to 'src/main/java/io')
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/CustomItems.java b/src/main/java/io/github/moulberry/notenoughupdates/CustomItems.java
index 28686073..06321b53 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/CustomItems.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/CustomItems.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates;
import com.google.gson.JsonArray;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java b/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java
index 38b59ef3..e1a3b3ee 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates;
import com.google.gson.Gson;
@@ -100,7 +119,6 @@ public class ItemPriceInformation {
}
}
-
NumberFormat format = NumberFormat.getInstance(Locale.US);
boolean shortNumber = NotEnoughUpdates.INSTANCE.config.tooltipTweaks.shortNumberFormatPrices;
if (bazaarItem) {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NEUApi.java b/src/main/java/io/github/moulberry/notenoughupdates/NEUApi.java
index feb18c66..6cdeb474 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/NEUApi.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/NEUApi.java
@@ -1,5 +1,23 @@
-package io.github.moulberry.notenoughupdates;
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+package io.github.moulberry.notenoughupdates;
import net.minecraftforge.fml.relauncher.ReflectionHelper;
public class NEUApi {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java b/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java
index ea92a670..c4efeb15 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates;
import com.google.gson.Gson;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NEUOverlay.java b/src/main/java/io/github/moulberry/notenoughupdates/NEUOverlay.java
index b8651867..5b1d3c14 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/NEUOverlay.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/NEUOverlay.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates;
import com.google.common.collect.Lists;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NEURepoResourcePack.java b/src/main/java/io/github/moulberry/notenoughupdates/NEURepoResourcePack.java
index 2a5cda92..bc279188 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/NEURepoResourcePack.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/NEURepoResourcePack.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates;
import com.google.gson.JsonObject;
@@ -7,69 +26,74 @@ import net.minecraft.client.resources.data.IMetadataSerializer;
import net.minecraft.util.ResourceLocation;
import java.awt.image.BufferedImage;
-import java.io.*;
+import java.io.BufferedInputStream;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.InputStream;
import java.util.HashSet;
import java.util.Set;
public class NEURepoResourcePack implements IResourcePack {
- File repoLocation;
- Set resourceDomains = new HashSet<>();
+ File repoLocation;
+ Set resourceDomains = new HashSet<>();
- public NEURepoResourcePack(File repoLocation, String domain) {
- this.repoLocation = repoLocation;
- resourceDomains.add(domain);
- }
+ public NEURepoResourcePack(File repoLocation, String domain) {
+ this.repoLocation = repoLocation;
+ resourceDomains.add(domain);
+ }
- public boolean loadRepoLocation() {
- if (repoLocation != null) return true;
- NotEnoughUpdates instance = NotEnoughUpdates.INSTANCE;
- if (instance == null) return false;
- NEUManager manager = instance.manager;
- if (manager == null) return false;
- repoLocation = manager.repoLocation;
- return repoLocation != null;
- }
+ public boolean loadRepoLocation() {
+ if (repoLocation != null) return true;
+ NotEnoughUpdates instance = NotEnoughUpdates.INSTANCE;
+ if (instance == null) return false;
+ NEUManager manager = instance.manager;
+ if (manager == null) return false;
+ repoLocation = manager.repoLocation;
+ return repoLocation != null;
+ }
- public File getFileForResource(ResourceLocation loc) {
- if (repoLocation == null) {
- if (!loadRepoLocation())
- return null;
- }
- if (!"neurepo".equals(loc.getResourceDomain())) {
- return null;
- }
- return new File(repoLocation, loc.getResourcePath());
- }
+ public File getFileForResource(ResourceLocation loc) {
+ if (repoLocation == null) {
+ if (!loadRepoLocation())
+ return null;
+ }
+ if (!"neurepo".equals(loc.getResourceDomain())) {
+ return null;
+ }
+ return new File(repoLocation, loc.getResourcePath());
+ }
- @Override
- public InputStream getInputStream(ResourceLocation resourceLocation) throws IOException {
- return new BufferedInputStream(new FileInputStream(getFileForResource(resourceLocation)));
- }
+ @Override
+ public InputStream getInputStream(ResourceLocation resourceLocation) throws IOException {
+ return new BufferedInputStream(new FileInputStream(getFileForResource(resourceLocation)));
+ }
- @Override
- public boolean resourceExists(ResourceLocation resourceLocation) {
- File file = getFileForResource(resourceLocation);
- return file != null && file.exists();
- }
+ @Override
+ public boolean resourceExists(ResourceLocation resourceLocation) {
+ File file = getFileForResource(resourceLocation);
+ return file != null && file.exists();
+ }
- @Override
- public Set getResourceDomains() {
- return resourceDomains;
- }
+ @Override
+ public Set getResourceDomains() {
+ return resourceDomains;
+ }
- @Override
- public T getPackMetadata(IMetadataSerializer iMetadataSerializer, String s) throws IOException {
- return iMetadataSerializer.parseMetadataSection(s, new JsonObject());
- }
+ @Override
+ public T getPackMetadata(IMetadataSerializer iMetadataSerializer, String s)
+ throws IOException {
+ return iMetadataSerializer.parseMetadataSection(s, new JsonObject());
+ }
- @Override
- public BufferedImage getPackImage() throws IOException {
- return null;
- }
+ @Override
+ public BufferedImage getPackImage() throws IOException {
+ return null;
+ }
- @Override
- public String getPackName() {
- return "NEU Repo Resources";
- }
+ @Override
+ public String getPackName() {
+ return "NEU Repo Resources";
+ }
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java b/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java
index cac89e77..9f7a98b1 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/NotEnoughUpdates.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates;
import com.google.common.collect.Sets;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java b/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java
index 80d2bca9..d4b6bd05 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/auction/APIManager.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.auction;
import com.google.gson.JsonArray;
@@ -27,7 +46,16 @@ import net.minecraft.util.ResourceLocation;
import java.io.ByteArrayInputStream;
import java.io.IOException;
-import java.util.*;
+import java.util.Base64;
+import java.util.ConcurrentModificationException;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Map;
+import java.util.NoSuchElementException;
+import java.util.Set;
+import java.util.TreeMap;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.function.Consumer;
@@ -214,7 +242,7 @@ public class APIManager {
lastBazaarUpdate = currentTime - BAZAAR_UPDATE_INTERVAL + 60 * 1000; // Try again in 1 minute on failure
updateBazaar();
}
- if (currentTime - lastLowestBinUpdate > LOWEST_BIN_UPDATE_INTERVAL) {
+ if (currentTime - lastLowestBinUpdate > LOWEST_BIN_UPDATE_INTERVAL) {
lastLowestBinUpdate = currentTime - LOWEST_BIN_UPDATE_INTERVAL + 30 * 1000; // Try again in 30 seconds on failure
updateLowestBin();
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
index 4fae9ea5..b5d34ed7 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.auction;
import com.google.gson.JsonObject;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAHGui.java b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAHGui.java
index 9311040d..ca85ca1c 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAHGui.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAHGui.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.auction;
import net.minecraft.client.gui.GuiScreen;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/ClientCommandBase.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/ClientCommandBase.java
index 8ba87ecd..e0ae7a1a 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/ClientCommandBase.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/ClientCommandBase.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands;
import net.minecraft.command.CommandBase;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
index ea401eb7..86411f4f 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
@@ -1,11 +1,41 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands;
-import io.github.moulberry.notenoughupdates.commands.dev.*;
+import io.github.moulberry.notenoughupdates.commands.dev.DevTestCommand;
+import io.github.moulberry.notenoughupdates.commands.dev.DiagCommand;
+import io.github.moulberry.notenoughupdates.commands.dev.DungeonWinTestCommand;
+import io.github.moulberry.notenoughupdates.commands.dev.NullzeeSphereCommand;
+import io.github.moulberry.notenoughupdates.commands.dev.PackDevCommand;
+import io.github.moulberry.notenoughupdates.commands.dev.ReloadRepoCommand;
+import io.github.moulberry.notenoughupdates.commands.dev.ResetRepoCommand;
+import io.github.moulberry.notenoughupdates.commands.dev.StatsCommand;
import io.github.moulberry.notenoughupdates.commands.dungeon.DhCommand;
import io.github.moulberry.notenoughupdates.commands.dungeon.DnCommand;
import io.github.moulberry.notenoughupdates.commands.dungeon.JoinDungeonCommand;
import io.github.moulberry.notenoughupdates.commands.dungeon.MapCommand;
-import io.github.moulberry.notenoughupdates.commands.help.*;
+import io.github.moulberry.notenoughupdates.commands.help.FeaturesCommand;
+import io.github.moulberry.notenoughupdates.commands.help.HelpCommand;
+import io.github.moulberry.notenoughupdates.commands.help.LinksCommand;
+import io.github.moulberry.notenoughupdates.commands.help.SettingsCommand;
+import io.github.moulberry.notenoughupdates.commands.help.StorageViewerWhyCommand;
import io.github.moulberry.notenoughupdates.commands.misc.AhCommand;
import io.github.moulberry.notenoughupdates.commands.misc.CalendarCommand;
import io.github.moulberry.notenoughupdates.commands.misc.CosmeticsCommand;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/EntityViewerCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/EntityViewerCommand.java
index c7b1862e..e3738661 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/EntityViewerCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/EntityViewerCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands;
import com.google.common.collect.Lists;
@@ -21,61 +40,61 @@ import java.util.Queue;
import java.util.concurrent.ConcurrentLinkedDeque;
public class EntityViewerCommand extends ClientCommandBase {
- public EntityViewerCommand() {
- super("neushowentity");
- MinecraftForge.EVENT_BUS.register(this);
- }
+ public EntityViewerCommand() {
+ super("neushowentity");
+ MinecraftForge.EVENT_BUS.register(this);
+ }
- @Override
- public List getCommandAliases() {
- return Lists.newArrayList("neuentityviewer");
- }
+ @Override
+ public List getCommandAliases() {
+ return Lists.newArrayList("neuentityviewer");
+ }
- @Override
- public String getCommandUsage(ICommandSender sender) {
- return EnumChatFormatting.RED + "Use /neushowentity list";
- }
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return EnumChatFormatting.RED + "Use /neushowentity list";
+ }
- public void showUsage(ICommandSender sender) {
- sender.addChatMessage(new ChatComponentText(getCommandUsage(sender)));
- }
+ public void showUsage(ICommandSender sender) {
+ sender.addChatMessage(new ChatComponentText(getCommandUsage(sender)));
+ }
- private final Queue queuedGUIS = new ConcurrentLinkedDeque<>();
+ private final Queue queuedGUIS = new ConcurrentLinkedDeque<>();
- @SubscribeEvent
- public void onTick(TickEvent event) {
- if (Minecraft.getMinecraft().currentScreen == null) {
- EntityViewer poll = queuedGUIS.poll();
- if (poll == null) return;
- Minecraft.getMinecraft().displayGuiScreen(poll);
- }
- }
+ @SubscribeEvent
+ public void onTick(TickEvent event) {
+ if (Minecraft.getMinecraft().currentScreen == null) {
+ EntityViewer poll = queuedGUIS.poll();
+ if (poll == null) return;
+ Minecraft.getMinecraft().displayGuiScreen(poll);
+ }
+ }
- @Override
- public void processCommand(ICommandSender sender, String[] strings) throws CommandException {
- if (strings.length == 0) {
- showUsage(sender);
- return;
- }
- if (strings[0].equals("list")) {
- for (String label : EntityViewer.validEntities.keySet()) {
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.BLUE + " " + label)
- .setChatStyle(new ChatStyle().setChatClickEvent(
- new ClickEvent(ClickEvent.Action.SUGGEST_COMMAND, "/neuentityviewer " + label))));
- }
- return;
- }
- EntityLivingBase entityLivingBase;
- if (strings[0].startsWith("@")) {
- ResourceLocation resourceLocation = new ResourceLocation(strings[0].substring(1));
- entityLivingBase = EntityViewer.constructEntity(resourceLocation);
- } else {
- entityLivingBase = EntityViewer.constructEntity(strings[0], Arrays.copyOfRange(strings, 1, strings.length));
- }
- if (entityLivingBase == null) {
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Could not create that entity"));
- return;
- }
- queuedGUIS.add(new EntityViewer(strings[0], entityLivingBase));
- }
+ @Override
+ public void processCommand(ICommandSender sender, String[] strings) throws CommandException {
+ if (strings.length == 0) {
+ showUsage(sender);
+ return;
+ }
+ if (strings[0].equals("list")) {
+ for (String label : EntityViewer.validEntities.keySet()) {
+ sender.addChatMessage(new ChatComponentText(EnumChatFormatting.BLUE + " " + label)
+ .setChatStyle(new ChatStyle().setChatClickEvent(
+ new ClickEvent(ClickEvent.Action.SUGGEST_COMMAND, "/neuentityviewer " + label))));
+ }
+ return;
+ }
+ EntityLivingBase entityLivingBase;
+ if (strings[0].startsWith("@")) {
+ ResourceLocation resourceLocation = new ResourceLocation(strings[0].substring(1));
+ entityLivingBase = EntityViewer.constructEntity(resourceLocation);
+ } else {
+ entityLivingBase = EntityViewer.constructEntity(strings[0], Arrays.copyOfRange(strings, 1, strings.length));
+ }
+ if (entityLivingBase == null) {
+ sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Could not create that entity"));
+ return;
+ }
+ queuedGUIS.add(new EntityViewer(strings[0], entityLivingBase));
+ }
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/ScreenCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/ScreenCommand.java
index 29dd9d55..1b90e5df 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/ScreenCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/ScreenCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands;
import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DevTestCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DevTestCommand.java
index 478f4db7..7cca9d3b 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DevTestCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DevTestCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DiagCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DiagCommand.java
index dab99698..326c00b4 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DiagCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DiagCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
@@ -49,8 +68,7 @@ public class DiagCommand extends ClientCommandBase {
CrystalMetalDetectorSolver.setDebugDoNotUseCenter(true);
sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW +
"Center coordinates-based solutions disabled"));
- }
- else if (subCommand.equals("center=on")) {
+ } else if (subCommand.equals("center=on")) {
CrystalMetalDetectorSolver.setDebugDoNotUseCenter(false);
sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW +
"Center coordinates-based solutions enabled"));
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DungeonWinTestCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DungeonWinTestCommand.java
index 223e154a..be25e697 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DungeonWinTestCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/DungeonWinTestCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.commands.ClientCommandBase;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/NullzeeSphereCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/NullzeeSphereCommand.java
index 64d64545..3a9ce90f 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/NullzeeSphereCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/NullzeeSphereCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.commands.ClientCommandBase;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/PackDevCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/PackDevCommand.java
index 2b0e7240..e1504472 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/PackDevCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/PackDevCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
@@ -25,51 +44,66 @@ import java.util.function.Supplier;
public class PackDevCommand extends ClientCommandBase {
static Minecraft mc = Minecraft.getMinecraft();
+
public PackDevCommand() {
super("neupackdev");
}
private static final HashMap> commands = new HashMap>() {{
- put("getnpc",
+ put(
+ "getnpc",
new Command<>(
"NPC",
() -> mc.theWorld.playerEntities,
true,
AbstractClientPlayer.class
- ));
- put("getnpcs",
+ )
+ );
+ put(
+ "getnpcs",
new Command<>(
"NPC",
() -> mc.theWorld.playerEntities,
false,
AbstractClientPlayer.class
- ));
- put("getmob",
+ )
+ );
+ put(
+ "getmob",
new Command<>(
"mob",
() -> mc.theWorld.loadedEntityList,
true,
EntityLiving.class
- ));
- put("getmobs",
+ )
+ );
+ put(
+ "getmobs",
new Command<>(
"mob",
() -> mc.theWorld.loadedEntityList,
false,
EntityLiving.class
- ));
- put("getarmorstand",
- new Command<>("armor stand",
+ )
+ );
+ put(
+ "getarmorstand",
+ new Command<>(
+ "armor stand",
() -> mc.theWorld.loadedEntityList,
true,
EntityArmorStand.class
- ));
- put("getarmorstands",
- new Command<>("armor stand",
+ )
+ );
+ put(
+ "getarmorstands",
+ new Command<>(
+ "armor stand",
() -> mc.theWorld.loadedEntityList,
false,
EntityArmorStand.class
- ));
+ )
+ );
}};
@Override
@@ -108,7 +142,7 @@ public class PackDevCommand extends ClientCommandBase {
StringBuilder output;
String subCommand = args[0].toLowerCase();
if (commands.containsKey(subCommand)) {
- Command,?> command = commands.get(subCommand);
+ Command, ?> command = commands.get(subCommand);
output = command.getData(dist);
} else if (subCommand.equals("getall")) {
output = getAll(dist);
@@ -184,7 +218,7 @@ public class PackDevCommand extends ClientCommandBase {
String heldItemString = heldItemTagCompound.toString();
NBTBase extraAttrTag = heldItemTagCompound.getTag("ExtraAttributes");
entityData
- .append(heldItemString != null ? heldItemString : "null")
+ .append(heldItemString != null ? heldItemString : "null")
.append("\nItem Tag Compound Extra Attributes: ")
.append(extraAttrTag != null ? extraAttrTag : "null");
} else {
@@ -201,12 +235,13 @@ public class PackDevCommand extends ClientCommandBase {
}
private static final String[] armorPieceTypes = {"Boots", "Leggings", "Chestplate", "Helmet"};
- public static StringBuilder armorDataBuilder (T entity) {
+
+ public static StringBuilder armorDataBuilder(T entity) {
StringBuilder armorData = new StringBuilder();
- for (int i=0; i < 4; i++) {
+ for (int i = 0; i < 4; i++) {
ItemStack currentArmor = entity.getCurrentArmor(0);
armorData.append(String.format("\n%s: ", armorPieceTypes[i]));
- if (currentArmor == null) {
+ if (currentArmor == null) {
armorData.append("null");
} else {
armorData.append(currentArmor.getTagCompound() != null ? currentArmor.getTagCompound().toString() : "null");
@@ -221,10 +256,12 @@ public class PackDevCommand extends ClientCommandBase {
Class clazz;
boolean single;
- Command(String typeFriendlyName,
- Supplier> entitySupplier,
- boolean single,
- Class clazz) {
+ Command(
+ String typeFriendlyName,
+ Supplier> entitySupplier,
+ boolean single,
+ Class clazz
+ ) {
this.typeFriendlyName = typeFriendlyName;
this.entitySupplier = entitySupplier;
this.single = single;
@@ -241,8 +278,8 @@ public class PackDevCommand extends ClientCommandBase {
continue;
}
T entityT = (T) entity;
- double entityDistanceSq = entity.getDistanceSq(mc.thePlayer.posX, mc.thePlayer.posY, mc.thePlayer.posZ);
- if (entityDistanceSq < distSq) {
+ double entityDistanceSq = entity.getDistanceSq(mc.thePlayer.posX, mc.thePlayer.posY, mc.thePlayer.posZ);
+ if (entityDistanceSq < distSq) {
if (single) {
distSq = entityDistanceSq;
closest = entityT;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ReloadRepoCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ReloadRepoCommand.java
index 40db245a..0bf57594 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ReloadRepoCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ReloadRepoCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ResetRepoCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ResetRepoCommand.java
index 9e8363fb..3f693898 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ResetRepoCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/ResetRepoCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/StatsCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/StatsCommand.java
index c7b6e887..756afc88 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/StatsCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dev/StatsCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with NotEnoughUpdates. If not, see .
+ */
+
package io.github.moulberry.notenoughupdates.commands.dev;
import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/dungeon/DhCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/dungeon/DhCommand.java
index 89299a36..222862f9 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/dungeon/DhCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/dungeon/DhCommand.java
@@ -1,3 +1,22 @@
+/*
+ * Copyright (C) 2022 NotEnoughUpdates contributors
+ *
+ * This file is part of NotEnoughUpdates.
+ *
+ * NotEnoughUpdates is free software: you can redistribute it
+ * and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * NotEnoughUpdates is distributed