mirror of
https://github.com/Xiao-MoMi/craft-engine.git
synced 2025-12-20 07:29:17 +00:00
修复meg方块实体渲染
This commit is contained in:
@@ -11,7 +11,6 @@ import net.momirealms.craftengine.core.world.World;
|
|||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.joml.Vector3f;
|
import org.joml.Vector3f;
|
||||||
|
|
||||||
// TODO not tested yet
|
|
||||||
public class ModelEngineBlockEntityElement implements BlockEntityElement {
|
public class ModelEngineBlockEntityElement implements BlockEntityElement {
|
||||||
private Dummy<?> dummy;
|
private Dummy<?> dummy;
|
||||||
private final Location location;
|
private final Location location;
|
||||||
@@ -41,14 +40,14 @@ public class ModelEngineBlockEntityElement implements BlockEntityElement {
|
|||||||
@Override
|
@Override
|
||||||
public void hide(Player player) {
|
public void hide(Player player) {
|
||||||
if (this.dummy != null) {
|
if (this.dummy != null) {
|
||||||
this.dummy.setForceViewing((org.bukkit.entity.Player) player.platformPlayer(), true);
|
this.dummy.setForceHidden((org.bukkit.entity.Player) player.platformPlayer(), true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void show(Player player) {
|
public void show(Player player) {
|
||||||
if (this.dummy != null) {
|
if (this.dummy != null) {
|
||||||
this.dummy.setForceHidden((org.bukkit.entity.Player) player.platformPlayer(), true);
|
this.dummy.setForceViewing((org.bukkit.entity.Player) player.platformPlayer(), true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user