mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 01:37:37 +00:00
Don't call ticking_list
on Spigot (#1655)
* ticking_list is paper only * Update adapters
This commit is contained in:
parent
d400a470a1
commit
1708584e8d
@ -481,7 +481,9 @@ public class PaperweightGetBlocks extends CharGetBlocks implements BukkitGetBloc
|
|||||||
// Don't attempt to tick section whilst we're editing
|
// Don't attempt to tick section whilst we're editing
|
||||||
if (existingSection != null) {
|
if (existingSection != null) {
|
||||||
PaperweightPlatformAdapter.clearCounts(existingSection);
|
PaperweightPlatformAdapter.clearCounts(existingSection);
|
||||||
existingSection.tickingList.clear();
|
if (PaperLib.isPaper()) {
|
||||||
|
existingSection.tickingList.clear();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (existingSection == null) {
|
if (existingSection == null) {
|
||||||
@ -503,7 +505,9 @@ public class PaperweightGetBlocks extends CharGetBlocks implements BukkitGetBloc
|
|||||||
//ensure that the server doesn't try to tick the chunksection while we're editing it (again).
|
//ensure that the server doesn't try to tick the chunksection while we're editing it (again).
|
||||||
DelegateSemaphore lock = PaperweightPlatformAdapter.applyLock(existingSection);
|
DelegateSemaphore lock = PaperweightPlatformAdapter.applyLock(existingSection);
|
||||||
PaperweightPlatformAdapter.clearCounts(existingSection);
|
PaperweightPlatformAdapter.clearCounts(existingSection);
|
||||||
existingSection.tickingList.clear();
|
if (PaperLib.isPaper()) {
|
||||||
|
existingSection.tickingList.clear();
|
||||||
|
}
|
||||||
|
|
||||||
synchronized (lock) {
|
synchronized (lock) {
|
||||||
// lock.acquire();
|
// lock.acquire();
|
||||||
|
@ -510,7 +510,9 @@ public class PaperweightGetBlocks extends CharGetBlocks implements BukkitGetBloc
|
|||||||
// Don't attempt to tick section whilst we're editing
|
// Don't attempt to tick section whilst we're editing
|
||||||
if (existingSection != null) {
|
if (existingSection != null) {
|
||||||
PaperweightPlatformAdapter.clearCounts(existingSection);
|
PaperweightPlatformAdapter.clearCounts(existingSection);
|
||||||
existingSection.tickingList.clear();
|
if (PaperLib.isPaper()) {
|
||||||
|
existingSection.tickingList.clear();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (createCopy) {
|
if (createCopy) {
|
||||||
@ -553,7 +555,9 @@ public class PaperweightGetBlocks extends CharGetBlocks implements BukkitGetBloc
|
|||||||
|
|
||||||
//ensure that the server doesn't try to tick the chunksection while we're editing it. (Again)
|
//ensure that the server doesn't try to tick the chunksection while we're editing it. (Again)
|
||||||
PaperweightPlatformAdapter.clearCounts(existingSection);
|
PaperweightPlatformAdapter.clearCounts(existingSection);
|
||||||
existingSection.tickingList.clear();
|
if (PaperLib.isPaper()) {
|
||||||
|
existingSection.tickingList.clear();
|
||||||
|
}
|
||||||
DelegateSemaphore lock = PaperweightPlatformAdapter.applyLock(existingSection);
|
DelegateSemaphore lock = PaperweightPlatformAdapter.applyLock(existingSection);
|
||||||
|
|
||||||
synchronized (lock) {
|
synchronized (lock) {
|
||||||
|
@ -514,6 +514,13 @@ public class PaperweightGetBlocks extends CharGetBlocks implements BukkitGetBloc
|
|||||||
|
|
||||||
LevelChunkSection newSection;
|
LevelChunkSection newSection;
|
||||||
LevelChunkSection existingSection = levelChunkSections[getSectionIndex];
|
LevelChunkSection existingSection = levelChunkSections[getSectionIndex];
|
||||||
|
// Don't attempt to tick section whilst we're editing
|
||||||
|
if (existingSection != null) {
|
||||||
|
PaperweightPlatformAdapter.clearCounts(existingSection);
|
||||||
|
if (PaperLib.isPaper()) {
|
||||||
|
existingSection.tickingList.clear();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (createCopy) {
|
if (createCopy) {
|
||||||
char[] tmpLoad = loadPrivately(layerNo);
|
char[] tmpLoad = loadPrivately(layerNo);
|
||||||
@ -564,7 +571,9 @@ public class PaperweightGetBlocks extends CharGetBlocks implements BukkitGetBloc
|
|||||||
|
|
||||||
//ensure that the server doesn't try to tick the chunksection while we're editing it. (Again)
|
//ensure that the server doesn't try to tick the chunksection while we're editing it. (Again)
|
||||||
PaperweightPlatformAdapter.clearCounts(existingSection);
|
PaperweightPlatformAdapter.clearCounts(existingSection);
|
||||||
existingSection.tickingList.clear();
|
if (PaperLib.isPaper()) {
|
||||||
|
existingSection.tickingList.clear();
|
||||||
|
}
|
||||||
DelegateSemaphore lock = PaperweightPlatformAdapter.applyLock(existingSection);
|
DelegateSemaphore lock = PaperweightPlatformAdapter.applyLock(existingSection);
|
||||||
|
|
||||||
synchronized (lock) {
|
synchronized (lock) {
|
||||||
|
Binary file not shown.
Loading…
Reference in New Issue
Block a user