mirror of
https://github.com/seppukudevelopment/seppuku
synced 2024-12-27 17:12:09 +00:00
BlockHighlight option for sizing visual when breaking
This commit is contained in:
parent
0ac2961e0c
commit
a9865f6580
@ -33,6 +33,7 @@ public final class BlockHighlightModule extends Module {
|
||||
public final Value<Integer> blue = new Value<Integer>("Blue", new String[]{"Blu", "b"}, "Blue value for the highlight visual.", 255, 0, 255, 1);
|
||||
public final Value<Integer> alpha = new Value<Integer>("Alpha", new String[]{"Alp", "Opacity", "a", "o"}, "Alpha value for the highlight visual.", 127, 0, 255, 1);
|
||||
public final Value<Float> width = new Value<Float>("Width", new String[]{"W", "size", "s"}, "Width value of the highlight visual.", 1.5f, 0.0f, 5.0f, 0.1f);
|
||||
public final Value<Boolean> breaking = new Value<Boolean>("Breaking", new String[]{"Break", "block", "brk"}, "Sizes the highlight visual based on the block breaking damage.", true);
|
||||
|
||||
public enum Mode {
|
||||
BOX, OUTLINE, CROSS
|
||||
@ -52,7 +53,12 @@ public final class BlockHighlightModule extends Module {
|
||||
final BlockPos blockpos = ray.getBlockPos();
|
||||
final IBlockState iblockstate = mc.world.getBlockState(blockpos);
|
||||
if (iblockstate.getMaterial() != Material.AIR && mc.world.getWorldBorder().contains(blockpos)) {
|
||||
float currentDamage = mc.playerController.curBlockDamageMP;
|
||||
float currentDamage;
|
||||
if (this.breaking.getValue()) {
|
||||
currentDamage = mc.playerController.curBlockDamageMP;
|
||||
} else {
|
||||
currentDamage = 0.0f;
|
||||
}
|
||||
|
||||
RenderUtil.begin3D();
|
||||
final Vec3d interp = MathUtil.interpolateEntity(mc.player, mc.getRenderPartialTicks());
|
||||
|
Loading…
Reference in New Issue
Block a user