mirror of
https://github.com/Xiao-MoMi/Custom-Crops.git
synced 2025-12-28 03:19:15 +00:00
date season commands
This commit is contained in:
@@ -101,7 +101,7 @@ public class SynchronizedCompoundMap {
|
||||
listJoiner.add(tag2.getValue().toString());
|
||||
}
|
||||
}
|
||||
tagValue = tag.getName() + "[" + listJoiner + "]";
|
||||
tagValue = "[" + listJoiner + "]";
|
||||
}
|
||||
case TAG_COMPOUND -> tagValue = compoundMapToString(tag.getName(), (CompoundMap) tag.getValue());
|
||||
default -> {
|
||||
|
||||
@@ -203,7 +203,9 @@ public class CustomCropsWorldImpl<W> implements CustomCropsWorld<W> {
|
||||
saveLazyChunks();
|
||||
saveLazyRegions();
|
||||
if (isANewDay()) {
|
||||
updateSeasonAndDate();
|
||||
if (setting().autoSeasonChange()) {
|
||||
updateSeasonAndDate();
|
||||
}
|
||||
}
|
||||
if (setting().enableScheduler()) {
|
||||
tickChunks();
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
package net.momirealms.customcrops.api.core.world;
|
||||
|
||||
import net.momirealms.customcrops.api.core.world.adaptor.WorldAdaptor;
|
||||
import net.momirealms.customcrops.api.integration.SeasonProvider;
|
||||
import net.momirealms.customcrops.common.plugin.feature.Reloadable;
|
||||
import org.bukkit.World;
|
||||
|
||||
@@ -26,6 +27,8 @@ import java.util.Set;
|
||||
|
||||
public interface WorldManager extends Reloadable {
|
||||
|
||||
SeasonProvider seasonProvider();
|
||||
|
||||
Season getSeason(World world);
|
||||
|
||||
int getDate(World world);
|
||||
|
||||
Reference in New Issue
Block a user