mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-12-27 02:58:03 +01:00
Fix static access issues.
This commit is contained in:
parent
15cdf3bfd6
commit
aeaad41c45
@ -183,8 +183,8 @@ public class EntityListener implements Listener {
|
||||
entity.setFireTicks(0);
|
||||
BleedTimer.remove(entity);
|
||||
Archery.arrowRetrievalCheck(entity);
|
||||
mcMMO.p.placeStore.removeSpawnedMob(((Entity) entity));
|
||||
mcMMO.p.placeStore.removeSpawnedPet(((Entity) entity));
|
||||
mcMMO.placeStore.removeSpawnedMob(((Entity) entity));
|
||||
mcMMO.placeStore.removeSpawnedPet(((Entity) entity));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -197,7 +197,7 @@ public class EntityListener implements Listener {
|
||||
SpawnReason reason = event.getSpawnReason();
|
||||
|
||||
if ((reason.equals(SpawnReason.SPAWNER) || reason.equals(SpawnReason.SPAWNER_EGG)) && !Config.getInstance().getExperienceGainsMobspawnersEnabled()) {
|
||||
mcMMO.p.placeStore.addSpawnedMob(((Entity) event.getEntity()));
|
||||
mcMMO.placeStore.addSpawnedMob(((Entity) event.getEntity()));
|
||||
}
|
||||
}
|
||||
|
||||
@ -398,7 +398,7 @@ public class EntityListener implements Listener {
|
||||
|
||||
if(player.hasMetadata("NPC")) return; // Check if this player is a Citizens NPC
|
||||
|
||||
if (Permissions.getInstance().taming(player) && !mcMMO.p.placeStore.isSpawnedPet((Entity) event.getEntity())) {
|
||||
if (Permissions.getInstance().taming(player) && !mcMMO.placeStore.isSpawnedPet((Entity) event.getEntity())) {
|
||||
PlayerProfile profile = Users.getProfile(player);
|
||||
EntityType type = event.getEntityType();
|
||||
int xp = 0;
|
||||
|
@ -51,6 +51,6 @@ public class WorldListener implements Listener {
|
||||
@EventHandler
|
||||
public void onChunkLoad(ChunkLoadEvent event) {
|
||||
if(event.getChunk().getEntities().length > 0)
|
||||
mcMMO.p.placeStore.loadChunk(event.getChunk().getX(), event.getChunk().getZ(), event.getWorld());
|
||||
mcMMO.placeStore.loadChunk(event.getChunk().getX(), event.getChunk().getZ(), event.getWorld());
|
||||
}
|
||||
}
|
||||
|
@ -67,7 +67,7 @@ public class CallOfTheWildEventHandler {
|
||||
return;
|
||||
|
||||
LivingEntity entity = (LivingEntity) player.getWorld().spawnEntity(player.getLocation(), type);
|
||||
mcMMO.p.placeStore.addSpawnedPet((Entity) entity);
|
||||
mcMMO.placeStore.addSpawnedPet((Entity) entity);
|
||||
|
||||
((Tameable) entity).setOwner(player);
|
||||
|
||||
|
@ -399,8 +399,8 @@ public class Combat {
|
||||
baseXP = 20 * configInstance.getPlayerVersusPlayerXP();
|
||||
}
|
||||
}
|
||||
else if (!mcMMO.p.placeStore.isSpawnedMob(((Entity) target))) {
|
||||
if (target instanceof Animals && !mcMMO.p.placeStore.isSpawnedPet((Entity) target)) {
|
||||
else if (!mcMMO.placeStore.isSpawnedMob(((Entity) target))) {
|
||||
if (target instanceof Animals && !mcMMO.placeStore.isSpawnedPet((Entity) target)) {
|
||||
baseXP = configInstance.getAnimalsXP();
|
||||
}
|
||||
else {
|
||||
|
Loading…
Reference in New Issue
Block a user