Updated multiple files

This commit is contained in:
Németh Noel 2021-06-30 12:59:38 +02:00
parent 8bd54dd300
commit b0af01ee89
3 changed files with 6 additions and 5 deletions

View File

@ -47,6 +47,7 @@ import org.jetbrains.annotations.Nullable;
import org.jglrxavpok.hephaistos.nbt.NBTCompound;
import java.time.Duration;
import java.time.temporal.TemporalUnit;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentLinkedQueue;
@ -1034,7 +1035,7 @@ public abstract class Instance implements BlockModifier, Tickable, TagHandler, P
* @param unit in what unit is the time expressed
* @param position the location of the block to update
*/
public abstract void scheduleUpdate(int time, @NotNull TimeUnit unit, @NotNull BlockPosition position);
public abstract void scheduleUpdate(int time, @NotNull TemporalUnit unit, @NotNull BlockPosition position);
/**
* Performs a single tick in the instance, including scheduled tasks from {@link #scheduleNextTick(Consumer)}.

View File

@ -24,13 +24,13 @@ import net.minestom.server.utils.callback.OptionalCallback;
import net.minestom.server.utils.chunk.ChunkCallback;
import net.minestom.server.utils.chunk.ChunkSupplier;
import net.minestom.server.utils.chunk.ChunkUtils;
import net.minestom.server.utils.time.TimeUnit;
import net.minestom.server.utils.validate.Check;
import net.minestom.server.world.DimensionType;
import net.minestom.server.world.biomes.Biome;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.time.temporal.TemporalUnit;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.CopyOnWriteArrayList;
@ -754,7 +754,7 @@ public class InstanceContainer extends Instance {
}
@Override
public void scheduleUpdate(int time, @NotNull TimeUnit unit, @NotNull BlockPosition position) {
public void scheduleUpdate(int time, @NotNull TemporalUnit unit, @NotNull BlockPosition position) {
final CustomBlock toUpdate = getCustomBlock(position);
if (toUpdate == null) {
return;

View File

@ -6,10 +6,10 @@ import net.minestom.server.storage.StorageLocation;
import net.minestom.server.utils.BlockPosition;
import net.minestom.server.utils.Position;
import net.minestom.server.utils.chunk.ChunkCallback;
import net.minestom.server.utils.time.TimeUnit;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.time.temporal.TemporalUnit;
import java.util.Collection;
import java.util.UUID;
@ -133,7 +133,7 @@ public class SharedInstance extends Instance {
}
@Override
public void scheduleUpdate(int time, @NotNull TimeUnit unit, @NotNull BlockPosition position) {
public void scheduleUpdate(int time, @NotNull TemporalUnit unit, @NotNull BlockPosition position) {
this.instanceContainer.scheduleUpdate(time, unit, position);
}