mirror of
https://github.com/PaperMC/Paper.git
synced 2026-11-25 10:29:41 -05:00
Added method to set spawn location
This commit is contained in:
1 parent
d142fabfc1
commit
e6583c0d48
1 file changed
+10
-1
@@ -68,7 +68,16 @@ public class CraftWorld implements World {
|
||||
ChunkCoordinates spawn = world.l();
|
||||
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) {
|
||||
return this.provider.d(x,z).bukkitChunk;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user