Fix update stuff
This commit is contained in:
parent
da2d60bf72
commit
419a5ab607
@ -7,7 +7,7 @@ minecraft_version=1.21.1
|
||||
yarn_mappings=1.21.1+build.3
|
||||
loader_version=0.16.0
|
||||
# Mod Properties
|
||||
mod_version=1.1.8+1.21.1
|
||||
mod_version=1.1.9
|
||||
maven_group=systems.brn.televator
|
||||
archives_base_name=televator
|
||||
# Dependencies
|
||||
|
@ -26,17 +26,17 @@ public class Televator implements ModInitializer {
|
||||
// Check if the player is sneaking
|
||||
if (player.isSneaking() && player.isOnGround()) {
|
||||
BlockPos testPos = player.getBlockPos().down();
|
||||
if(player.getWorld().getBlockState(testPos).getBlock() instanceof TelevatorBlock jumpVaderBlock) {
|
||||
jumpVaderBlock.handleMovement(testPos, player, false);
|
||||
if(player.getWorld().getBlockState(testPos).getBlock() instanceof TelevatorBlock televatorBlock) {
|
||||
televatorBlock.handleMovement(testPos, player, false);
|
||||
}
|
||||
}
|
||||
|
||||
// Check if the player is jumping
|
||||
if (player.getVelocity().y > 0 && !player.isOnGround()) {
|
||||
BlockPos testPos = player.getBlockPos().down();
|
||||
if(player.getWorld().getBlockState(testPos).getBlock() instanceof TelevatorBlock jumpVaderBlock)
|
||||
if(player.getWorld().getBlockState(testPos).getBlock() instanceof TelevatorBlock televatorBlock)
|
||||
{
|
||||
jumpVaderBlock.handleMovement(testPos, player, true);
|
||||
televatorBlock.handleMovement(testPos, player, true);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user