mirror of
https://github.com/Multiverse/Multiverse-Core.git
synced 2024-11-07 11:20:32 +01:00
Fixed shouldWeKillThisCreature() in MVEntityListener.
This commit is contained in:
parent
91c9e175d0
commit
dc0121509a
@ -124,7 +124,7 @@ public class MVEntityListener extends EntityListener {
|
|||||||
} else if (creatureList.isEmpty()) {
|
} else if (creatureList.isEmpty()) {
|
||||||
// 2. There are no exceptions and animals are NOT allowed. Kill it.
|
// 2. There are no exceptions and animals are NOT allowed. Kill it.
|
||||||
return true;
|
return true;
|
||||||
} else if (creatureList.contains(creature) && allowCreatureSpawning) {
|
} else if (creatureList.contains(creature.toUpperCase()) && allowCreatureSpawning) {
|
||||||
// 3. There ARE exceptions and animals ARE allowed. Kill it.
|
// 3. There ARE exceptions and animals ARE allowed. Kill it.
|
||||||
return true;
|
return true;
|
||||||
} else if (!creatureList.contains(creature.toUpperCase()) && allowCreatureSpawning) {
|
} else if (!creatureList.contains(creature.toUpperCase()) && allowCreatureSpawning) {
|
||||||
@ -136,9 +136,10 @@ public class MVEntityListener extends EntityListener {
|
|||||||
} else if (!creatureList.contains(creature.toUpperCase()) && !allowCreatureSpawning) {
|
} else if (!creatureList.contains(creature.toUpperCase()) && !allowCreatureSpawning) {
|
||||||
// 6. Animals are NOT allowed to spawn, and this creature is not in the save list... KILL IT
|
// 6. Animals are NOT allowed to spawn, and this creature is not in the save list... KILL IT
|
||||||
return true;
|
return true;
|
||||||
}
|
} else {
|
||||||
// This code should NEVER execute. I just left the verbose conditions in right now.
|
// This code should NEVER execute. I just left the verbose conditions in right now.
|
||||||
return false;
|
throw new UnsupportedOperationException();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user