Skip to content

Commit 54eeb54

Browse files
committed
Merge branch 'main' into 1.19
# Conflicts: # CHANGELOG.md # Common/src/generated/resources/data/hexdebug/advancements/recipes/hexdebug.hexdebug/evaluator.json # Common/src/main/kotlin/gay/object/hexdebug/debugger/HexDebugger.kt # Common/src/main/kotlin/gay/object/hexdebug/registry/HexDebugItems.kt # Common/src/main/resources/assets/hexdebug/lang/en_us.flatten.json5 # Common/src/main/resources/hexdebug-common.mixins.json # Forge/src/main/kotlin/gay/object/hexdebug/forge/ForgeHexDebug.kt # Forge/src/main/kotlin/gay/object/hexdebug/forge/datagen/HexDebugRecipes.kt # gradle.properties
2 parents 0f5c08d + 6e4de32 commit 54eeb54

File tree

34 files changed

+541
-48
lines changed

34 files changed

+541
-48
lines changed

CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,22 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and [Pydantic's HISTORY.md](https://github.com/pydantic/pydantic/blob/main/HISTORY.md), and this project *mostly* adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [UNRELEASED]
8+
9+
### Added
10+
11+
- New item: Evaluator!
12+
- A staff that allows evaluating expressions in an ongoing debug session. The stack and ravenmind update to reflect the state of the Debugger whenever it changes.
13+
- When the Evaluator's grid is cleared, the Debugger is reset to the state it was in just before the first pattern was drawn in the Evaluator.
14+
- New config options:
15+
- Open Debug Port: Whether or not a port should be opened. If false, the Debugger effectively becomes useless.
16+
- Smart Debugger Sneak-Scroll: If a hex is not currently being debugged and a Debugger is in your main hand, prefer shift-scrolling whatever item is in your offhand (eg. a spellbook).
17+
- This was already a feature; it's just configurable now.
18+
19+
### Changed
20+
21+
- Moved some relatively unimportant log messages from INFO to DEBUG.
22+
723
## 0.1.1+1.19.2
824

925
- Initial version for 1.19.2.

Common/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,5 +29,5 @@ dependencies {
2929

3030
api(libs.bundles.lsp4j)
3131

32-
implementation(libs.ktor.network)
32+
implementation(libs.bundles.ktor)
3333
}

Common/src/generated/resources/assets/hexdebug/models/item/debugger.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"parent": "minecraft:item/generated",
2+
"parent": "minecraft:item/handheld_rod",
33
"overrides": [
44
{
55
"model": "hexdebug:item/debugger/not_debugging/continue/empty",
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"parent": "minecraft:item/handheld_rod",
3+
"overrides": [
4+
{
5+
"model": "hexdebug:item/evaluator/default",
6+
"predicate": {
7+
"hexdebug:eval_state": 0.0
8+
}
9+
},
10+
{
11+
"model": "hexdebug:item/evaluator/modified",
12+
"predicate": {
13+
"hexdebug:eval_state": 0.5
14+
}
15+
}
16+
],
17+
"textures": {
18+
"layer0": "hexdebug:item/evaluator"
19+
}
20+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"parent": "hexdebug:item/evaluator"
3+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"parent": "hexdebug:item/evaluator",
3+
"textures": {
4+
"layer1": "hexdebug:item/evaluator/eval_state/modified"
5+
}
6+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"values": [
3+
"hexdebug:evaluator"
4+
]
5+
}

Common/src/generated/resources/data/hexdebug/recipes/debugger.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
{
22
"type": "minecraft:crafting_shaped",
33
"key": {
4-
"A": {
5-
"item": "hexcasting:artifact"
6-
},
74
"C": {
85
"item": "hexcasting:charged_amethyst"
96
},
10-
"G": {
7+
"L": {
118
"item": "minecraft:gold_ingot"
9+
},
10+
"U": {
11+
"item": "hexcasting:artifact"
1212
}
1313
},
1414
"pattern": [
1515
" CC",
16-
" AC",
17-
"G "
16+
" UC",
17+
"L "
1818
],
1919
"result": {
2020
"item": "hexdebug:debugger"
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"type": "minecraft:crafting_shaped",
3+
"category": "equipment",
4+
"key": {
5+
"C": {
6+
"item": "hexcasting:charged_amethyst"
7+
},
8+
"L": {
9+
"item": "hexcasting:slate_block"
10+
},
11+
"U": {
12+
"item": "hexcasting:slate_block"
13+
}
14+
},
15+
"pattern": [
16+
" CC",
17+
" UC",
18+
"L "
19+
],
20+
"result": {
21+
"item": "hexdebug:evaluator"
22+
},
23+
"show_notification": true
24+
}

Common/src/main/java/gay/object/hexdebug/mixin/MixinShiftScrollListener.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
package gay.object.hexdebug.mixin;
22

33
import at.petrak.hexcasting.client.ShiftScrollListener;
4-
import com.llamalad7.mixinextras.injector.wrapoperation.Operation;
5-
import com.llamalad7.mixinextras.injector.wrapoperation.WrapOperation;
4+
import gay.object.hexdebug.config.HexDebugConfig;
65
import gay.object.hexdebug.items.ItemDebugger;
76
import gay.object.hexdebug.registry.HexDebugItems;
87
import net.minecraft.client.Minecraft;
98
import net.minecraft.world.item.Item;
109
import org.jetbrains.annotations.Contract;
1110
import org.spongepowered.asm.mixin.Mixin;
1211
import org.spongepowered.asm.mixin.Shadow;
13-
import org.spongepowered.asm.mixin.gen.Accessor;
1412
import org.spongepowered.asm.mixin.gen.Invoker;
1513
import org.spongepowered.asm.mixin.injection.At;
1614
import org.spongepowered.asm.mixin.injection.Inject;
@@ -45,6 +43,7 @@ public abstract class MixinShiftScrollListener {
4543
&& (player.isShiftKeyDown() || !needsSneaking)
4644
&& !player.isSpectator()
4745
// additional logic
46+
&& HexDebugConfig.INSTANCE.get().getClient().getSmartDebuggerSneakScroll()
4847
&& !ItemDebugger.isDebugging()
4948
&& player.getMainHandItem().getItem() == HexDebugItems.DEBUGGER.getValue()
5049
&& hexdebug$invokeIsScrollableItem(player.getOffhandItem().getItem())

0 commit comments

Comments
 (0)