mirror of
https://github.com/Minestom/Minestom.git
synced 2025-02-08 16:32:07 +01:00
Replaced ChronoUnit with TimeUnit for consistency
This commit is contained in:
parent
c037ea9d84
commit
01dfe2f48d
@ -45,6 +45,7 @@ import net.minestom.server.utils.chunk.ChunkUtils;
|
||||
import net.minestom.server.utils.entity.EntityUtils;
|
||||
import net.minestom.server.utils.player.PlayerUtils;
|
||||
import net.minestom.server.utils.time.Cooldown;
|
||||
import net.minestom.server.utils.time.TimeUnit;
|
||||
import net.minestom.server.utils.validate.Check;
|
||||
import org.jetbrains.annotations.ApiStatus;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
@ -52,7 +53,6 @@ import org.jetbrains.annotations.Nullable;
|
||||
import org.jglrxavpok.hephaistos.nbt.NBTCompound;
|
||||
|
||||
import java.time.Duration;
|
||||
import java.time.temporal.ChronoUnit;
|
||||
import java.time.temporal.TemporalUnit;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
@ -128,7 +128,7 @@ public class Entity implements Viewable, Tickable, EventHandler<EntityEvent>, Da
|
||||
protected EntityType entityType; // UNSAFE to change, modify at your own risk
|
||||
|
||||
// Network synchronization, send the absolute position of the entity each X milliseconds
|
||||
private static final Duration SYNCHRONIZATION_COOLDOWN = Duration.of(1, ChronoUnit.MINUTES);
|
||||
private static final Duration SYNCHRONIZATION_COOLDOWN = Duration.of(1, TimeUnit.MINUTE);
|
||||
private Duration customSynchronizationCooldown;
|
||||
private long lastAbsoluteSynchronizationTime;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user