Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
7d58e23
BME-150 / BME-151 - start laying the ground for integration
LordFokas Sep 18, 2024
65a3378
Fix tiny mistake
LordFokas Sep 19, 2024
cb6e89f
BME-166 / BME-150 - SyntheticLayers and MapType layer stack manipulation
LordFokas Sep 19, 2024
8d0378a
BME-150: Display FTB Chunks claims on Blaze Map
LordFokas Sep 19, 2024
fa2f2ca
BME-192: Make UI buttons show object owners
LordFokas Sep 20, 2024
87089f7
BME-150: use Layer.Type instead of instanceof FakeLayer
LordFokas Sep 20, 2024
fcd5154
BME-151: manage FTBChunks claims in Blaze Map
LordFokas Sep 20, 2024
a573883
BME-194: Overlays
LordFokas Sep 24, 2024
c1efa5f
Merge branch 'mc-1.18.2-staging' into integration-ftbchunks
LordFokas Sep 24, 2024
ee1bdea
Remove IScreenSkipsMinimap -- it was a stupid idea.
LordFokas Sep 24, 2024
d99f70b
Make GridOverlay only render chunk borders at 1:1 and closer
LordFokas Sep 27, 2024
cbf56c5
BME-82: Internal UI Library -- begin work
LordFokas Sep 27, 2024
4b0127b
BME-82: Create spacers, add headers to button containers
LordFokas Sep 27, 2024
c73378d
BME-82: Move the Atlas Export info panel to its own component
LordFokas Sep 28, 2024
00beb71
BME-82: Renderable API interface. Make Layer legends use it. Create W…
LordFokas Oct 1, 2024
b8b30b6
BME-82 / BME-194: extract entities and waypoint code from MapRenderer…
LordFokas Oct 2, 2024
ab3bd12
Bump to 0.8.0-dev.0
LordFokas Oct 2, 2024
545a7dd
All layers have icons, disable bottom layers, some cleanup.
LordFokas Oct 2, 2024
8219a49
BME-182: allow server to disable maps / layers / overlays
LordFokas Oct 3, 2024
73c3d04
Merge branch 'mc-1.18.2' into mc-1.18.2-v0.8.0-overhaul
LordFokas Oct 3, 2024
bc66b45
clean up after merge
LordFokas Oct 3, 2024
e2e6a07
clean up after merge
LordFokas Oct 4, 2024
ad6b756
BME-80 / BME-82: UI overhaul, fragment system, better waypoint editor
LordFokas Oct 11, 2024
4bea312
little cleanup
LordFokas Oct 11, 2024
5407244
Move stuff around a lot
LordFokas Oct 11, 2024
d421256
minor cleanup
LordFokas Oct 11, 2024
8f6c15f
BME-29 / BME-83: begin work; detach waypoints from engine
LordFokas Oct 14, 2024
a65e249
BME-82: Fixed slider being keyed in reverse
LordFokas Oct 14, 2024
58ef8bc
Tidy up some classes
LordFokas Oct 15, 2024
4647614
Enhance icons, use color, grayscale shader. Moved some classes.
LordFokas Oct 15, 2024
444b948
Death waypoints
LordFokas Oct 15, 2024
1d879b8
Fix wrapped vanilla components with poorly written vertex shaders
LordFokas Oct 15, 2024
027eaa5
Clean up grayscale shader a bit
LordFokas Oct 15, 2024
d1483f8
Better overlay icons
LordFokas Oct 16, 2024
27b7108
Fix component buttons shader interaction with forbidden components
LordFokas Oct 17, 2024
32fd965
BME-29 / BME-83: first batch of work. Also misc fixes.
LordFokas Oct 19, 2024
74e3b27
Switch TreeContainer to use a glScissor instead of hiding children
LordFokas Oct 19, 2024
fc83bd1
Make IconTabs better
LordFokas Oct 20, 2024
13ea128
Minimap scissor test (fix large objects rendering out of bounds)
LordFokas Oct 20, 2024
ac15227
New headers for Overlays and Layers
LordFokas Oct 22, 2024
6dd1ffc
BME-29 / BME-83: second batch of work - tree list management
LordFokas Oct 22, 2024
9868752
BME-29 / BME-83: Add and edit waypoints from manager; some cleanup
LordFokas Oct 23, 2024
105c9f7
Touch up edit button contrast
LordFokas Oct 23, 2024
4bafb50
BME-29 / BME-83: 4th batch of work - dropdowns and dimension picking
LordFokas Nov 1, 2024
09ab62c
BME-102: require items to write and read maps.
LordFokas Feb 7, 2025
b669605
BME-102: bind waypoints and other map UI under the same restrictions …
LordFokas Feb 8, 2025
92cb22d
BME-29 / BME-83: add dimension selector to waypoint manager; localize…
LordFokas Feb 8, 2025
a8bbfe7
BME-170: use more realistic block colors from the textures themselves
LordFokas Feb 14, 2025
d34639b
BME-123: map flowers by their petal colors
LordFokas Feb 14, 2025
bce1018
BME-29/BME-83: Break out WaypointManagerFragment inner classes
LordFokas Feb 15, 2025
46cc2b9
BME-131 [WIP] Transparency progress squashed commit
maddie-j Feb 17, 2025
067f771
BME-29/BME-83: Allow editing waypoint group names
LordFokas Feb 18, 2025
1d97861
Clean leftover import
LordFokas Feb 18, 2025
e202f06
Merge pull request #85 from maddie-j/main-1.18.2
LordFokas Feb 18, 2025
2ced9ec
BME-23 / BME-217 - Break WorldMapGui into a component-based GUI
LordFokas Mar 31, 2025
bde8877
Add keybind to toggle minimap visibility
dudebehinddude Jul 12, 2025
cf8ffb4
Merge pull request #88 from dudebehinddude/mc-1.18.2-v0.8.0-overhaul
LordFokas Jul 22, 2025
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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ eclipse
run
resources/__pycache__
libs
tmp

# Files from Forge MDK
forge*changelog.txt
11 changes: 10 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'maven-publish'

version = '0.5.19-dev.7'
version = '0.8.0-dev.0'
group = 'com.eerussianguy.blazemap' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
archivesBaseName = "BlazeMap-${minecraft_version}"

Expand Down Expand Up @@ -76,6 +76,15 @@ dependencies {
// implementation fg.deobf("_:TerraFirmaCraft:Forge-1.18.2-2.1.11-beta")
// implementation fg.deobf("_:Cartography:1.18.2-0.4.0-alpha3")

implementation fg.deobf("_:ftb-chunks:${ftbchunks_version}")
implementation fg.deobf("_:ftb-teams:${ftbteams_version}")
implementation fg.deobf("_:ftb-library:$ftblib_version")
implementation fg.deobf("_:architectury:${architectury_version}")

// implementation fg.deobf("_:journeymap:1.20.1-5.10.0-forge")
// implementation fg.deobf("_:Xaeros_Minimap:24.2.0_Forge_1.20")
// implementation fg.deobf("_:XaerosWorldMap:1.38.8_Forge_1.20")


// Apply Mixin AP
annotationProcessor 'org.spongepowered:mixin:0.8.5:processor'
Expand Down
10 changes: 8 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,13 @@
# This is required to provide enough memory for the Minecraft decompilation process.
org.gradle.jvmargs=-Xmx4G
org.gradle.daemon=false
mappings_channel=official
mappings_version=1.18.2

minecraft_version=1.18.2
forge_version=40.2.17
mappings_channel=official
mappings_version=1.18.2

ftbchunks_version=forge-1802.3.19-build.362
ftbteams_version=forge-1802.2.11-build.107
ftblib_version=forge-1802.3.11-build.177
architectury_version=4.12.94-forge
37 changes: 28 additions & 9 deletions src/main/java/com/eerussianguy/blazemap/BlazeMap.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
package com.eerussianguy.blazemap;

import java.util.List;

import net.minecraft.resources.ResourceLocation;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.eventbus.api.IEventBus;
import net.minecraftforge.fml.IExtensionPoint;
Expand All @@ -9,13 +12,16 @@
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
import net.minecraftforge.fml.loading.FMLEnvironment;

import com.eerussianguy.blazemap.api.BlazeMapAPI;
import com.eerussianguy.blazemap.config.BlazeMapConfig;
import com.eerussianguy.blazemap.engine.client.BlazeMapClientEngine;
import com.eerussianguy.blazemap.engine.server.BlazeMapServerEngine;
import com.eerussianguy.blazemap.engine.RegistryController;
import com.eerussianguy.blazemap.engine.client.ClientEngine;
import com.eerussianguy.blazemap.engine.server.ServerEngine;
import com.eerussianguy.blazemap.feature.BlazeMapCommandsClient;
import com.eerussianguy.blazemap.feature.BlazeMapFeaturesClient;
import com.eerussianguy.blazemap.feature.BlazeMapFeaturesCommon;
import com.eerussianguy.blazemap.integration.KnownMods;
import com.eerussianguy.blazemap.integration.ModIntegration;
import com.eerussianguy.blazemap.integration.ftbchunks.FTBChunksPlugin;
import com.mojang.logging.LogUtils;
import org.slf4j.Logger;

Expand All @@ -28,6 +34,14 @@ public class BlazeMap {
public static final String MOD_ID = "blazemap";
public static final String MOD_NAME = "Blaze Map";

public static final List<ModIntegration> INTEGRATIONS = List.of(
new FTBChunksPlugin()
);

public static ResourceLocation resource(String name) {
return new ResourceLocation(MOD_ID, name);
}

public BlazeMap() {
ModLoadingContext.get().registerExtensionPoint(IExtensionPoint.DisplayTest.class, () -> new IExtensionPoint.DisplayTest(() -> "Nothing", (remote, isServer) -> true));
final IEventBus bus = FMLJavaModLoadingContext.get().getModEventBus();
Expand All @@ -43,26 +57,26 @@ public BlazeMap() {
// DebuggingEventHandler.init();
}
else {
// These are forbidden in the dedicated server.
// Client side objects are forbidden in the dedicated server.
// The others are frozen by the RegistryController when the time comes.
BlazeMapAPI.LAYERS.freeze();
BlazeMapAPI.MAPTYPES.freeze();
BlazeMapAPI.OBJECT_RENDERERS.freeze();
RegistryController.freezeClientRegistries();
}
}

public void setup(FMLCommonSetupEvent event) {
KnownMods.init();

// We are client side, enable client engine. Required on client.
if(FMLEnvironment.dist == Dist.CLIENT) {
BlazeMapClientEngine.init();
ClientEngine.init();
}

// Regardless of side, server engine is optional.
// This might be helpful later on, on server side, where we want the engine off but other features on.
// So removing the mod to disable the server engine will not be an option.
// For now, though, there are no other server features.
if(BlazeMapConfig.COMMON.enableServerEngine.get()){
BlazeMapServerEngine.init();
ServerEngine.init();
}

// Initialize common sided features
Expand All @@ -71,9 +85,14 @@ public void setup(FMLCommonSetupEvent event) {
// Initialize client-only features
if(FMLEnvironment.dist == Dist.CLIENT) {
BlazeMapFeaturesClient.initMapping();
BlazeMapFeaturesClient.initOverlays();
BlazeMapFeaturesClient.initMaps();
BlazeMapFeaturesClient.initWaypoints();
BlazeMapCommandsClient.init();
}

for(var integration : INTEGRATIONS) {
integration.init();
}
}
}
6 changes: 3 additions & 3 deletions src/main/java/com/eerussianguy/blazemap/FMLEventHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent;
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;

import com.eerussianguy.blazemap.feature.Overlays;
import com.eerussianguy.blazemap.feature.IngameOverlays;


public class FMLEventHandler {
Expand All @@ -18,10 +18,10 @@ public static void init() {
}

private static void clientSetup(final FMLClientSetupEvent event) {
Overlays.reload();
IngameOverlays.reload();
}

private static void onConfigReload(ModConfigEvent.Reloading event) {
Overlays.reload();
IngameOverlays.reload();
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.eerussianguy.blazemap.gui;
package com.eerussianguy.blazemap.__deprecated;

import javax.annotation.Nonnull;

Expand All @@ -11,16 +11,17 @@
import net.minecraft.network.chat.TextComponent;
import net.minecraft.resources.ResourceLocation;

import com.eerussianguy.blazemap.util.Colors;
import com.eerussianguy.blazemap.util.Helpers;
import com.eerussianguy.blazemap.util.RenderHelper;
import com.eerussianguy.blazemap.BlazeMap;
import com.eerussianguy.blazemap.lib.Colors;
import com.eerussianguy.blazemap.lib.RenderHelper;
import com.mojang.blaze3d.vertex.PoseStack;
import com.mojang.blaze3d.vertex.Tesselator;

@Deprecated
public abstract class BlazeGui extends Screen {
private static final TextComponent EMPTY = new TextComponent("");
public static final ResourceLocation SLOT = Helpers.identifier("textures/gui/slot.png");
public static final ResourceLocation GUI = Helpers.identifier("textures/gui/gui.png");
public static final ResourceLocation SLOT = BlazeMap.resource("textures/gui/slot.png");
public static final ResourceLocation GUI = BlazeMap.resource("textures/gui/gui.png");

protected final RenderType background, slot;
protected int guiWidth, guiHeight;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,26 +1,33 @@
package com.eerussianguy.blazemap.feature.maps;
package com.eerussianguy.blazemap.__deprecated;

import net.minecraft.ChatFormatting;
import net.minecraft.client.gui.components.ImageButton;
import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.TextComponent;

import com.eerussianguy.blazemap.api.BlazeRegistry.Key;
import com.eerussianguy.blazemap.api.maps.Layer;
import com.eerussianguy.blazemap.api.maps.MapType;
import com.eerussianguy.blazemap.util.Colors;
import com.eerussianguy.blazemap.util.RenderHelper;
import com.mojang.blaze3d.systems.RenderSystem;
import com.eerussianguy.blazemap.feature.maps.ui.MapHost;
import com.eerussianguy.blazemap.integration.KnownMods;
import com.eerussianguy.blazemap.lib.Colors;
import com.eerussianguy.blazemap.lib.RenderHelper;
import com.mojang.blaze3d.vertex.PoseStack;

@Deprecated
public class LayerButton extends ImageButton {
private final Key<Layer> key;
private final MapType parent;
private final IMapHost host;
private final MapHost host;
private final Component owner;

public LayerButton(int px, int py, int w, int h, Key<Layer> key, MapType parent, IMapHost host) {
public LayerButton(int px, int py, int w, int h, Key<Layer> key, MapType parent, MapHost host) {
super(px, py, w, h, 0, 0, 0, key.value().getIcon(), w, h, button -> {
host.toggleLayer(key);
}, key.value().getName());
this.key = key;
this.parent = parent;
this.owner = new TextComponent(KnownMods.getOwnerName(key)).withStyle(ChatFormatting.BLUE);
this.host = host;
checkVisible();
}
Expand All @@ -37,8 +44,8 @@ public void render(PoseStack stack, int mx, int my, float partial) {

@Override
public void renderToolTip(PoseStack stack, int x, int y) {
RenderSystem.setShaderColor(1, 1, 1, 1);
host.drawTooltip(stack, key.value().getName(), x, y);
//RenderSystem.setShaderColor(1, 1, 1, 1);
//host.drawTooltip(stack, x, y, key.value().getName(), owner);
}

public void checkVisible() {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,39 +1,43 @@
package com.eerussianguy.blazemap.feature.maps;
package com.eerussianguy.blazemap.__deprecated;

import net.minecraft.ChatFormatting;
import net.minecraft.client.gui.components.ImageButton;
import net.minecraft.client.gui.components.events.GuiEventListener;
import net.minecraft.network.chat.TranslatableComponent;
import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.TextComponent;

import com.eerussianguy.blazemap.api.BlazeRegistry.Key;
import com.eerussianguy.blazemap.api.maps.MapType;
import com.eerussianguy.blazemap.util.Colors;
import com.eerussianguy.blazemap.util.RenderHelper;
import com.mojang.blaze3d.systems.RenderSystem;
import com.eerussianguy.blazemap.feature.maps.ui.MapHost;
import com.eerussianguy.blazemap.integration.KnownMods;
import com.eerussianguy.blazemap.lib.Colors;
import com.eerussianguy.blazemap.lib.RenderHelper;
import com.mojang.blaze3d.vertex.PoseStack;

@Deprecated
public class MapTypeButton extends ImageButton {
private final Key<MapType> key;
private final IMapHost host;
private final MapHost host;
private final Component owner;

public MapTypeButton(int px, int py, int w, int h, Key<MapType> key, IMapHost host) {
public MapTypeButton(int px, int py, int w, int h, Key<MapType> key, MapHost host) {
super(px, py, w, h, 0, 0, 0, key.value().getIcon(), w, h, button -> {
host.setMapType(key.value());
for(GuiEventListener widget : host.getChildren()) {
/*for(GuiEventListener widget : host.getChildren()) {
if(widget instanceof LayerButton lb) {
lb.checkVisible();
}
}
}*/
}, key.value().getName());

this.host = host;
this.key = key;
this.owner = new TextComponent(KnownMods.getOwnerName(key)).withStyle(ChatFormatting.BLUE);
}

@Override
public void renderToolTip(PoseStack stack, int x, int y) {
RenderSystem.setShaderColor(1, 1, 1, 1);
TranslatableComponent component = key.value().getName();
host.drawTooltip(stack, component, x, y);
//RenderSystem.setShaderColor(1, 1, 1, 1);
//host.drawTooltip(stack, x, y, key.value().getName(), owner);
}

@Override
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/com/eerussianguy/blazemap/api/BlazeMapAPI.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.eerussianguy.blazemap.api.maps.Layer;
import com.eerussianguy.blazemap.api.maps.MapType;
import com.eerussianguy.blazemap.api.maps.Overlay;
import com.eerussianguy.blazemap.api.markers.ObjectRenderer;
import com.eerussianguy.blazemap.api.pipeline.*;

Expand All @@ -28,5 +29,6 @@ public class BlazeMapAPI {
public static final BlazeRegistry<Layer> LAYERS = new BlazeRegistry<>();

public static final BlazeRegistry<MapType> MAPTYPES = new BlazeRegistry<>();
public static final BlazeRegistry<Overlay> OVERLAYS = new BlazeRegistry<>();
public static final BlazeRegistry<ObjectRenderer<?>> OBJECT_RENDERERS = new BlazeRegistry<>();
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

import com.eerussianguy.blazemap.api.maps.Layer;
import com.eerussianguy.blazemap.api.maps.MapType;
import com.eerussianguy.blazemap.api.maps.Overlay;
import com.eerussianguy.blazemap.api.markers.ObjectRenderer;
import com.eerussianguy.blazemap.api.pipeline.Collector;
import com.eerussianguy.blazemap.api.pipeline.DataType;
Expand Down Expand Up @@ -54,6 +55,17 @@ public static class MapTypes {
public static final Key<MapType> NETHER = new Key<>(MAPTYPES, MODID, "nether");
}

public static class Overlays {
public static final Key<Overlay> GRID = new Key<>(OVERLAYS, MODID, "grid");
public static final Key<Overlay> PLAYERS = new Key<>(OVERLAYS, MODID, "players");
public static final Key<Overlay> NPCS = new Key<>(OVERLAYS, MODID, "npcs");
public static final Key<Overlay> ANIMALS = new Key<>(OVERLAYS, MODID, "animals");
public static final Key<Overlay> ENEMIES = new Key<>(OVERLAYS, MODID, "enemies");
public static final Key<Overlay> WAYPOINTS = new Key<>(OVERLAYS, MODID, "waypoints");

public static final Key<Overlay> FTBCHUNKS = new Key<>(OVERLAYS, MODID, "ftbchunks");
}

public static class ObjectRenderers {
public static final Key<ObjectRenderer<?>> DEFAULT = new Key<>(OBJECT_RENDERERS, MODID, "default");
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.eerussianguy.blazemap.api.event;

import net.minecraftforge.eventbus.api.Event;

/**
* Fired immediately after all registries have been frozen.
* Used by systems that need to be sure the registries will no longer be changed.
*
* @author LordFokas
*/
public class BlazeRegistriesFrozenEvent extends Event {}
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import com.eerussianguy.blazemap.api.BlazeRegistry;
import com.eerussianguy.blazemap.api.maps.Layer;
import com.eerussianguy.blazemap.api.maps.MapType;
import com.eerussianguy.blazemap.api.maps.Overlay;
import com.eerussianguy.blazemap.api.markers.ObjectRenderer;
import com.eerussianguy.blazemap.api.pipeline.*;

Expand Down Expand Up @@ -64,6 +65,12 @@ public MapTypeRegistryEvent() {
}
}

public static class OverlayRegistryEvent extends BlazeRegistryEvent<Overlay> {
public OverlayRegistryEvent() {
super(BlazeMapAPI.OVERLAYS);
}
}

public static class ObjectRendererRegistryEvent extends BlazeRegistryEvent<ObjectRenderer<?>> {
public ObjectRendererRegistryEvent() {
super(BlazeMapAPI.OBJECT_RENDERERS);
Expand Down
Loading