Update to 1.21
This commit is contained in:
parent
24a61bcd23
commit
719702cb6d
@ -4,16 +4,16 @@ org.gradle.parallel=true
|
|||||||
|
|
||||||
# Fabric Properties
|
# Fabric Properties
|
||||||
# check these on https://fabricmc.net/develop
|
# check these on https://fabricmc.net/develop
|
||||||
minecraft_version=1.20.6
|
minecraft_version=1.21
|
||||||
yarn_mappings=1.20.6+build.3
|
yarn_mappings=1.21+build.1
|
||||||
loader_version=0.15.11
|
loader_version=0.15.11
|
||||||
|
|
||||||
# Mod Properties
|
# Mod Properties
|
||||||
mod_version = 1.1.3+1.20.6
|
mod_version = 1.1.4+1.21
|
||||||
maven_group = systems.brn.televator
|
maven_group = systems.brn.televator
|
||||||
archives_base_name = televator
|
archives_base_name = televator
|
||||||
|
|
||||||
# Dependencies
|
# Dependencies
|
||||||
fabric_version=0.99.0+1.20.6
|
fabric_version=0.100.1+1.21
|
||||||
polymer_version=0.8.0+1.20.6
|
polymer_version=0.8.4+1.20.6
|
||||||
server_translations_api_version=2.3.0+1.20.5-rc2
|
server_translations_api_version=2.3.0+1.20.5-rc2
|
||||||
|
@ -30,7 +30,7 @@ public class TelevatorBlock extends Block implements PolymerTexturedBlock {
|
|||||||
|
|
||||||
public TelevatorBlock(Settings settings, BlockModelType type, String modelId) {
|
public TelevatorBlock(Settings settings, BlockModelType type, String modelId) {
|
||||||
super(settings);
|
super(settings);
|
||||||
this.polymerBlockState = PolymerBlockResourceUtils.requestBlock(type, PolymerBlockModel.of(new Identifier(Televator.MODID, modelId)));
|
this.polymerBlockState = PolymerBlockResourceUtils.requestBlock(type, PolymerBlockModel.of(Identifier.of(Televator.MODID, modelId)));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -39,7 +39,7 @@ public class TelevatorBlock extends Block implements PolymerTexturedBlock {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static void register() {
|
public static void register() {
|
||||||
var modId = new Identifier(Televator.MODID, Televator.MODELID);
|
var modId = Identifier.of(Televator.MODID, Televator.MODELID);
|
||||||
var block = Registry.register(Registries.BLOCK, modId,
|
var block = Registry.register(Registries.BLOCK, modId,
|
||||||
new TelevatorBlock(AbstractBlock.Settings.copy(Blocks.WHITE_WOOL), BlockModelType.FULL_BLOCK, Televator.MODELID));
|
new TelevatorBlock(AbstractBlock.Settings.copy(Blocks.WHITE_WOOL), BlockModelType.FULL_BLOCK, Televator.MODELID));
|
||||||
|
|
||||||
@ -69,7 +69,8 @@ public class TelevatorBlock extends Block implements PolymerTexturedBlock {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void teleportWithEffect(ServerPlayerEntity player, ServerWorld w, BlockPos tpPos) {
|
private void teleportWithEffect(ServerPlayerEntity player, ServerWorld w, BlockPos tpPos) {
|
||||||
player.teleport(tpPos.getX() + 0.5f, tpPos.getY(), tpPos.getZ() + 0.5f);
|
|
||||||
|
player.teleport(tpPos.getX() + 0.5d, tpPos.getY(), tpPos.getZ() + 0.5d, true);
|
||||||
player.setVelocity(0, 0, 0);
|
player.setVelocity(0, 0, 0);
|
||||||
player.setSneaking(false);
|
player.setSneaking(false);
|
||||||
w.playSound(null, tpPos, SoundEvents.ENTITY_ENDERMAN_TELEPORT, SoundCategory.PLAYERS, 0.5f, 1.5f);
|
w.playSound(null, tpPos, SoundEvents.ENTITY_ENDERMAN_TELEPORT, SoundCategory.PLAYERS, 0.5f, 1.5f);
|
||||||
|
@ -18,7 +18,7 @@ public class TelevatorBlockItem extends BlockItem implements PolymerItem {
|
|||||||
|
|
||||||
public TelevatorBlockItem(Settings settings, Block block, String modelId) {
|
public TelevatorBlockItem(Settings settings, Block block, String modelId) {
|
||||||
super(block, settings);
|
super(block, settings);
|
||||||
this.polymerModel = PolymerResourcePackUtils.requestModel(Items.BARRIER, new Identifier(Televator.MODID, modelId));
|
this.polymerModel = PolymerResourcePackUtils.requestModel(Items.BARRIER, Identifier.of(Televator.MODID, modelId));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user