mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-03 23:07:40 +01:00
Added API to allow plugins to set the world's spawn flags.
By: EvilSeph <evilseph@unaligned.org>
This commit is contained in:
parent
250810823d
commit
797f79e621
@ -618,6 +618,28 @@ public interface World {
|
||||
*/
|
||||
public ChunkSnapshot getEmptyChunkSnapshot(int x, int z, boolean includeBiome, boolean includeBiomeTempRain);
|
||||
|
||||
/**
|
||||
* Sets the spawn flags for this.
|
||||
*
|
||||
* @param allowMonsters - if true, monsters are allowed to spawn in this world.
|
||||
* @param allowAnimals - if true, animals are allowed to spawn in this world.
|
||||
*/
|
||||
public void setSpawnFlags(boolean allowMonsters, boolean allowAnimals);
|
||||
|
||||
/**
|
||||
* Gets whether animals can spawn in this world.
|
||||
*
|
||||
* @return whether animals can spawn in this world.
|
||||
*/
|
||||
public boolean getAllowAnimals();
|
||||
|
||||
/**
|
||||
* Gets whether monsters can spawn in this world.
|
||||
*
|
||||
* @return whether monsters can spawn in this world.
|
||||
*/
|
||||
public boolean getAllowMonsters();
|
||||
|
||||
/**
|
||||
* Represents various map environment types that a world may be
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user