mirror of
https://github.com/DRE2N/DungeonsXL.git
synced 2024-11-24 19:45:43 +01:00
Fix #62
This commit is contained in:
parent
cac3e3de39
commit
5699cc142b
@ -67,7 +67,7 @@ Instead of referencing the internals of the implementation directly, DungeonsXL
|
||||
The shaded version of DXL (standard version) contains this library, while the original version needs it as an external plugin.
|
||||
Have a look at the [installation instructions](../../wiki/getting-started#installation) for detailed information.
|
||||
|
||||
DungeonsXL currently uses BRCommons 0.5.
|
||||
DungeonsXL currently uses BRCommons 0.5.1.
|
||||
|
||||
### Java
|
||||
7 and higher
|
||||
|
2
pom.xml
2
pom.xml
@ -2,7 +2,7 @@
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>io.github.dre2n</groupId>
|
||||
<artifactId>dungeonsxl</artifactId>
|
||||
<version>0.11-SNAPSHOT</version>
|
||||
<version>0.11</version>
|
||||
<packaging>jar</packaging>
|
||||
<name>DungeonsXL</name>
|
||||
<url>https://dre2n.github.io</url>
|
||||
|
@ -38,7 +38,6 @@ import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.EventPriority;
|
||||
import org.bukkit.event.Listener;
|
||||
import org.bukkit.event.entity.CreatureSpawnEvent;
|
||||
import org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason;
|
||||
import org.bukkit.event.entity.EntityCombustByEntityEvent;
|
||||
import org.bukkit.event.entity.EntityCombustEvent;
|
||||
import org.bukkit.event.entity.EntityDamageByEntityEvent;
|
||||
@ -71,8 +70,11 @@ public class EntityListener implements Listener {
|
||||
GameWorld gameWorld = GameWorld.getByWorld(world);
|
||||
|
||||
if (editWorld != null || gameWorld != null) {
|
||||
if (event.getSpawnReason() == SpawnReason.CHUNK_GEN || event.getSpawnReason() == SpawnReason.BREEDING || event.getSpawnReason() == SpawnReason.NATURAL
|
||||
|| event.getSpawnReason() == SpawnReason.DEFAULT) {
|
||||
switch (event.getSpawnReason()) {
|
||||
case CHUNK_GEN:
|
||||
case JOCKEY:
|
||||
case MOUNT:
|
||||
case NATURAL:
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user