mirror of
https://github.com/PaperMC/Paper.git
synced 2025-03-02 11:22:01 +01:00
Added method to set spawn location
By: SpeaKeasY <mekevin1917@gmail.com>
This commit is contained in:
parent
93b688f5bf
commit
be2b78fb4c
@ -68,7 +68,16 @@ public class CraftWorld implements World {
|
|||||||
ChunkCoordinates spawn = world.l();
|
ChunkCoordinates spawn = world.l();
|
||||||
return new Location(this, spawn.a, world.e(spawn.a, spawn.c), spawn.c);
|
return new Location(this, spawn.a, world.e(spawn.a, spawn.c), spawn.c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean setSpawnLocation(int x, int y, int z) {
|
||||||
|
try {
|
||||||
|
world.q.a(x, y, z);
|
||||||
|
return true;
|
||||||
|
} catch (Exception e) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public Chunk getChunkAt(int x, int z) {
|
public Chunk getChunkAt(int x, int z) {
|
||||||
return this.provider.d(x,z).bukkitChunk;
|
return this.provider.d(x,z).bukkitChunk;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user