Merge pull request #2059 from Lucwousin/boner-config-check
deathindicators: Fix permabones config check
This commit is contained in:
@@ -229,24 +229,24 @@ public class DeathIndicatorPlugin extends Plugin
|
|||||||
|
|
||||||
private void onPlayerDeath(PlayerDeath death)
|
private void onPlayerDeath(PlayerDeath death)
|
||||||
{
|
{
|
||||||
if (client.isInInstancedRegion() || death.getPlayer().getWorldLocation().getRegionID() == 13362)
|
if (client.isInInstancedRegion())
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (death.getPlayer() != client.getLocalPlayer())
|
final Player player = death.getPlayer();
|
||||||
|
|
||||||
|
if (config.permaBones() && player.getWorldLocation().getRegionID() != 13362)
|
||||||
|
{
|
||||||
|
newBoneFor(player);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (player != client.getLocalPlayer())
|
||||||
{
|
{
|
||||||
newBoneFor(death.getPlayer());
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Player lp = client.getLocalPlayer();
|
lastDeath = player.getWorldLocation();
|
||||||
if (config.permaBones())
|
|
||||||
{
|
|
||||||
newBoneFor(lp);
|
|
||||||
}
|
|
||||||
|
|
||||||
lastDeath = lp.getWorldLocation();
|
|
||||||
lastDeathWorld = client.getWorld();
|
lastDeathWorld = client.getWorld();
|
||||||
lastDeathTime = Instant.now();
|
lastDeathTime = Instant.now();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user