send help
This commit is contained in:
parent
80155ba7bc
commit
c45f5f6029
@ -342,7 +342,7 @@ abstract class MatteryBlockEntity(p_155228_: BlockEntityType<*>, p_155229_: Bloc
|
|||||||
optional.invalidate()
|
optional.invalidate()
|
||||||
|
|
||||||
if (SERVER_IS_LIVE)
|
if (SERVER_IS_LIVE)
|
||||||
level?.once { setChanged() }
|
level?.once { if (!this@MatteryBlockEntity.isRemoved) setChanged() }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -354,7 +354,7 @@ abstract class MatteryBlockEntity(p_155228_: BlockEntityType<*>, p_155229_: Bloc
|
|||||||
optional = LazyOptional.of { capability }
|
optional = LazyOptional.of { capability }
|
||||||
|
|
||||||
if (SERVER_IS_LIVE)
|
if (SERVER_IS_LIVE)
|
||||||
level?.once { setChanged() }
|
level?.once { if (!this@MatteryBlockEntity.isRemoved) setChanged() }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -365,7 +365,7 @@ abstract class MatteryBlockEntity(p_155228_: BlockEntityType<*>, p_155229_: Bloc
|
|||||||
optional.invalidate()
|
optional.invalidate()
|
||||||
|
|
||||||
if (SERVER_IS_LIVE)
|
if (SERVER_IS_LIVE)
|
||||||
level?.once { setChanged() }
|
level?.once { if (!this@MatteryBlockEntity.isRemoved) setChanged() }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -377,7 +377,7 @@ abstract class MatteryBlockEntity(p_155228_: BlockEntityType<*>, p_155229_: Bloc
|
|||||||
optional = LazyOptional.of { capability }
|
optional = LazyOptional.of { capability }
|
||||||
|
|
||||||
if (SERVER_IS_LIVE)
|
if (SERVER_IS_LIVE)
|
||||||
level?.once { setChanged() }
|
level?.once { if (!this@MatteryBlockEntity.isRemoved) setChanged() }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -491,8 +491,10 @@ abstract class MatteryBlockEntity(p_155228_: BlockEntityType<*>, p_155229_: Bloc
|
|||||||
if (isRemoved) markSynchronizerClean()
|
if (isRemoved) markSynchronizerClean()
|
||||||
|
|
||||||
if (level?.isClientSide == false && (_subCache == null || (_subCache ?: throw ConcurrentModificationException()).players.isNotEmpty())) {
|
if (level?.isClientSide == false && (_subCache == null || (_subCache ?: throw ConcurrentModificationException()).players.isNotEmpty())) {
|
||||||
ru.dbotthepony.mc.otm.onceServer {
|
onceServer {
|
||||||
synchronizeToPlayers(true)
|
if (!isRemoved) {
|
||||||
|
synchronizeToPlayers(true)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
markSynchronizerClean()
|
markSynchronizerClean()
|
||||||
@ -527,8 +529,10 @@ abstract class MatteryBlockEntity(p_155228_: BlockEntityType<*>, p_155229_: Bloc
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
level.once {
|
level.once {
|
||||||
for (side in _sides.values) {
|
if (!isRemoved) {
|
||||||
side.updateTracked()
|
for (side in _sides.values) {
|
||||||
|
side.updateTracked()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -675,7 +679,9 @@ abstract class MatteryBlockEntity(p_155228_: BlockEntityType<*>, p_155229_: Bloc
|
|||||||
if (!blockEntities.add(blockEntity)) return
|
if (!blockEntities.add(blockEntity)) return
|
||||||
|
|
||||||
onceServer {
|
onceServer {
|
||||||
blockEntity.synchronizeToPlayers(false)
|
if (!blockEntity.isRemoved && blockEntity in blockEntities) {
|
||||||
|
blockEntity.synchronizeToPlayers(false)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (blockEntity.synchronizer.hasObservers && blockEntity.tickList.ticks == 0) {
|
if (blockEntity.synchronizer.hasObservers && blockEntity.tickList.ticks == 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user