-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: 1.20.6 port, gametests all pass
- Loading branch information
1 parent
f51131e
commit 9568afb
Showing
32 changed files
with
61 additions
and
577 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
- Add automated testing. | ||
- Add `rightclickharvest:blacklist` block tag. | ||
|
||
1.20.6 update coming soon :) | ||
- Port 4.2.0 to 1.20.6. | ||
- Forge and Quilt support has been removed (see Discord announcements channel for reasoning). | ||
- `RightClickHarvestFabricLikeCallbacks` has been renamed to `RightClickHarvestFabricCallbacks` (API). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
9 changes: 0 additions & 9 deletions
9
...n/java/io/github/jamalam360/rightclickharvest/fabriclike/RightClickHarvestFabricLike.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 5 additions & 5 deletions
10
.../src/main/java/io/github/jamalam360/rightclickharvest/fabric/RightClickHarvestFabric.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
package io.github.jamalam360.rightclickharvest.fabric; | ||
|
||
import io.github.jamalam360.rightclickharvest.fabriclike.RightClickHarvestFabricLike; | ||
import io.github.jamalam360.rightclickharvest.RightClickHarvest; | ||
import net.fabricmc.api.ModInitializer; | ||
|
||
public class RightClickHarvestFabric implements ModInitializer { | ||
|
||
@Override | ||
public void onInitialize() { | ||
RightClickHarvestFabricLike.init(); | ||
} | ||
@Override | ||
public void onInitialize() { | ||
RightClickHarvest.init(); | ||
} | ||
} |
4 changes: 2 additions & 2 deletions
4
...RightClickHarvestFabricLikeCallbacks.java → ...ric/RightClickHarvestFabricCallbacks.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 11 additions & 11 deletions
22
...ain/java/io/github/jamalam360/rightclickharvest/fabric/RightClickHarvestPlatformImpl.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,24 @@ | ||
package io.github.jamalam360.rightclickharvest.fabric; | ||
|
||
import io.github.jamalam360.rightclickharvest.HarvestContext; | ||
import io.github.jamalam360.rightclickharvest.fabriclike.RightClickHarvestFabricLikeCallbacks; | ||
import net.fabricmc.fabric.api.event.player.PlayerBlockBreakEvents; | ||
import net.minecraft.core.BlockPos; | ||
import net.minecraft.world.entity.player.Player; | ||
import net.minecraft.world.level.Level; | ||
import net.minecraft.world.level.block.state.BlockState; | ||
|
||
public class RightClickHarvestPlatformImpl { | ||
public static void postAfterHarvestEvent(HarvestContext context) { | ||
RightClickHarvestFabricLikeCallbacks.AFTER_HARVEST.invoker().afterHarvest(context); | ||
} | ||
|
||
public static boolean postBreakEvent(Level level, BlockPos pos, BlockState state, Player player) { | ||
return !PlayerBlockBreakEvents.BEFORE.invoker().beforeBlockBreak(level, player, pos, state, level.getBlockEntity(pos)); | ||
} | ||
public static void postAfterHarvestEvent(HarvestContext context) { | ||
RightClickHarvestFabricCallbacks.AFTER_HARVEST.invoker().afterHarvest(context); | ||
} | ||
|
||
public static boolean postPlaceEvent(Level level, BlockPos pos, Player player) { | ||
// no-op, fabric doesn't have a specific place block event. | ||
return false; | ||
} | ||
public static boolean postBreakEvent(Level level, BlockPos pos, BlockState state, Player player) { | ||
return !PlayerBlockBreakEvents.BEFORE.invoker().beforeBlockBreak(level, player, pos, state, level.getBlockEntity(pos)); | ||
} | ||
|
||
public static boolean postPlaceEvent(Level level, BlockPos pos, Player player) { | ||
// no-op, fabric doesn't have a specific place block event. | ||
return false; | ||
} | ||
} |
Oops, something went wrong.