Track BlockProjectileSource causes.

This commit is contained in:
wizjany 2020-04-24 10:06:16 -04:00
parent 662ae2bc84
commit 37e66dae7d

View File

@ -36,6 +36,7 @@
import org.bukkit.entity.Tameable;
import org.bukkit.entity.Vehicle;
import org.bukkit.metadata.Metadatable;
import org.bukkit.projectiles.BlockProjectileSource;
import javax.annotation.Nullable;
import java.util.ArrayList;
@ -289,6 +290,8 @@ private void addAll(@Nullable Object... element) {
} else if (o instanceof Tameable) {
indirect = true;
addAll(((Tameable) o).getOwner());
} else if (o instanceof BlockProjectileSource) {
addAll(((BlockProjectileSource) o).getBlock());
}
// Add manually tracked parent causes