|
1 | 1 | package xaeroplus.fabric.gametest; |
2 | 2 |
|
| 3 | +import it.unimi.dsi.fastutil.longs.Long2LongArrayMap; |
3 | 4 | import net.fabricmc.fabric.api.client.gametest.v1.FabricClientGameTest; |
4 | 5 | import net.fabricmc.fabric.api.client.gametest.v1.context.ClientGameTestContext; |
5 | 6 | import net.minecraft.client.Minecraft; |
|
17 | 18 | import xaero.map.WorldMapSession; |
18 | 19 | import xaero.map.gui.GuiMap; |
19 | 20 | import xaero.map.gui.GuiWorldMapSettings; |
| 21 | +import xaeroplus.Globals; |
20 | 22 | import xaeroplus.feature.extensions.DrawOrderScreen; |
21 | 23 | import xaeroplus.feature.extensions.SyncedWaypoint; |
| 24 | +import xaeroplus.feature.render.DrawFeatureFactory; |
22 | 25 | import xaeroplus.feature.render.line.Line; |
23 | 26 | import xaeroplus.feature.render.text.Text; |
24 | 27 | import xaeroplus.feature.waypoint.WaypointAPI; |
@@ -55,6 +58,14 @@ public void runTest(ClientGameTestContext context) { |
55 | 58 | var lz = ChunkUtils.chunkCoordToCoord(ChunkUtils.actualPlayerChunkZ()); |
56 | 59 | ModuleManager.getModule(Drawing.class).addLine(new Line(lx - 128, lz - 128, lx + 128, lz + 128), ColorHelper.getColor(255, 0, 0, 200)); |
57 | 60 | ModuleManager.getModule(Drawing.class).addText(new Text("bottom text", lx, lz + 64, ColorHelper.getColor(255, 255, 255, 255), 1f)); |
| 61 | + var testHighlights = new Long2LongArrayMap(); |
| 62 | + testHighlights.put(ChunkUtils.chunkPosToLong(ChunkUtils.actualPlayerChunkX() - 5, ChunkUtils.actualPlayerChunkZ() + 5), 0); |
| 63 | + Globals.drawManager.registry().register(DrawFeatureFactory.chunkHighlights( |
| 64 | + "test", |
| 65 | + dim -> testHighlights, |
| 66 | + () -> ColorHelper.getColor(0, 255, 0, 150), |
| 67 | + 50 |
| 68 | + )); |
58 | 69 | HudMod.INSTANCE.getHudConfigs().getClientConfigManager().getCurrentProfile().set(MinimapProfiledConfigOptions.SIZE, 200); |
59 | 70 | HudMod.INSTANCE.getHudConfigs().getClientConfigManager().getCurrentProfile().set(MinimapProfiledConfigOptions.NORTH_LOCKED, true); |
60 | 71 | HudMod.INSTANCE.getHudConfigs().getClientConfigManager().getCurrentProfile().set(MinimapProfiledConfigOptions.WAYPOINT_DISTANCE_IN_WORLD, 2); |
|
0 commit comments