--- a/net/minecraft/world/level/block/WeightedPressurePlateBlock.java
+++ b/net/minecraft/world/level/block/WeightedPressurePlateBlock.java
@@ -13,8 +13,10 @@
 import net.minecraft.world.level.block.state.StateDefinition;
 import net.minecraft.world.level.block.state.properties.BlockStateProperties;
 import net.minecraft.world.level.block.state.properties.IntegerProperty;
+import org.bukkit.event.entity.EntityInteractEvent; // CraftBukkit
 
 public class WeightedPressurePlateBlock extends BasePressurePlateBlock {
+
     public static final IntegerProperty POWER = BlockStateProperties.POWER;
     private final int maxWeight;
     private final SoundEvent soundOff;
@@ -22,7 +24,7 @@
 
     protected WeightedPressurePlateBlock(int weight, BlockBehaviour.Properties settings, SoundEvent depressSound, SoundEvent pressSound) {
         super(settings);
-        this.registerDefaultState(this.stateDefinition.any().setValue(POWER, Integer.valueOf(0)));
+        this.registerDefaultState((BlockState) ((BlockState) this.stateDefinition.any()).setValue(WeightedPressurePlateBlock.POWER, 0));
         this.maxWeight = weight;
         this.soundOff = depressSound;
         this.soundOn = pressSound;
@@ -30,9 +32,35 @@
 
     @Override
     protected int getSignalStrength(Level world, BlockPos pos) {
-        int i = Math.min(world.getEntitiesOfClass(Entity.class, TOUCH_AABB.move(pos)).size(), this.maxWeight);
+        // CraftBukkit start
+        // int i = Math.min(world.getEntitiesOfClass(Entity.class, BlockPressurePlateWeighted.TOUCH_AABB.move(blockposition)).size(), this.maxWeight);
+        int i = 0;
+        java.util.Iterator iterator = world.getEntitiesOfClass(Entity.class, WeightedPressurePlateBlock.TOUCH_AABB.move(pos)).iterator();
+
+        while (iterator.hasNext()) {
+            Entity entity = (Entity) iterator.next();
+
+            org.bukkit.event.Cancellable cancellable;
+
+            if (entity instanceof Player) {
+                cancellable = org.bukkit.craftbukkit.v1_19_R2.event.CraftEventFactory.callPlayerInteractEvent((Player) entity, org.bukkit.event.block.Action.PHYSICAL, pos, null, null, null);
+            } else {
+                cancellable = new EntityInteractEvent(entity.getBukkitEntity(), world.getWorld().getBlockAt(pos.getX(), pos.getY(), pos.getZ()));
+                world.getCraftServer().getPluginManager().callEvent((EntityInteractEvent) cancellable);
+            }
+
+            // We only want to block turning the plate on if all events are cancelled
+            if (!cancellable.isCancelled()) {
+                i++;
+            }
+        }
+
+        i = Math.min(i, this.maxWeight);
+        // CraftBukkit end
+
         if (i > 0) {
-            float f = (float)Math.min(this.maxWeight, i) / (float)this.maxWeight;
+            float f = (float) Math.min(this.maxWeight, i) / (float) this.maxWeight;
+
             return Mth.ceil(f * 15.0F);
         } else {
             return 0;
@@ -41,22 +69,22 @@
 
     @Override
     protected void playOnSound(LevelAccessor world, BlockPos pos) {
-        world.playSound((Player)null, pos, this.soundOn, SoundSource.BLOCKS);
+        world.playSound((Player) null, pos, this.soundOn, SoundSource.BLOCKS);
     }
 
     @Override
     protected void playOffSound(LevelAccessor world, BlockPos pos) {
-        world.playSound((Player)null, pos, this.soundOff, SoundSource.BLOCKS);
+        world.playSound((Player) null, pos, this.soundOff, SoundSource.BLOCKS);
     }
 
     @Override
     protected int getSignalForState(BlockState state) {
-        return state.getValue(POWER);
+        return (Integer) state.getValue(WeightedPressurePlateBlock.POWER);
     }
 
     @Override
     protected BlockState setSignalForState(BlockState state, int rsOut) {
-        return state.setValue(POWER, Integer.valueOf(rsOut));
+        return (BlockState) state.setValue(WeightedPressurePlateBlock.POWER, rsOut);
     }
 
     @Override
@@ -66,6 +94,6 @@
 
     @Override
     protected void createBlockStateDefinition(StateDefinition.Builder<Block, BlockState> builder) {
-        builder.add(POWER);
+        builder.add(WeightedPressurePlateBlock.POWER);
     }
 }
