NPE check for bed location.
This commit is contained in:
parent
9deec24e98
commit
4038c1182e
Binary file not shown.
@ -43,7 +43,7 @@ public class DeathManager {
|
|||||||
p.setVelocity(new Vector(0,0,0));
|
p.setVelocity(new Vector(0,0,0));
|
||||||
CustomDamage.removeIframe(p);
|
CustomDamage.removeIframe(p);
|
||||||
Location loc = p.getLocation();
|
Location loc = p.getLocation();
|
||||||
loc.setY(p.getBedSpawnLocation().getY());
|
if (p.getBedSpawnLocation()!=null) {loc.setY(p.getBedSpawnLocation().getY());}
|
||||||
p.teleport(loc);
|
p.teleport(loc);
|
||||||
}},1);
|
}},1);
|
||||||
PlayerStructure pd = PlayerStructure.GetPlayerStructure(p);
|
PlayerStructure pd = PlayerStructure.GetPlayerStructure(p);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user