VolumeEntry class

Пакет: com.hypixel.hytale.builtin.triggervolumes.manager

Файл: com/hypixel/hytale/builtin/triggervolumes/manager/VolumeEntry.java

Поля (11)

МодификаторыТипИмя
VOLUME, VOLUME_REJECTION, GROUP, GROUP_REJECTION
IntOpenHashSet var1
LinkedHashMap var1
SpatialSnapshot var2
SpatialSnapshot var2
SpatialSnapshot var2
long var4
String var4
String var4
String var5
long var6

Методы (75)

МодификаторыВозвратСигнатура
EffectBucket EffectBucket()
public record EffectEntityKeyrecord EffectEntityKey(@Nonnull VolumeEntry.EffectBucket bucket, int effectIndex, @Nonnull UUID entityId)
public record EntryEntityKeyrecord EntryEntityKey(int entry, @Nonnull UUID entityId)
public record GroupEntityKeyrecord GroupEntityKey(@Nonnull String groupId, int entry, @Nonnull UUID entityId)
void attachOwnervoid attachOwner(@Nonnull TriggerVolumeManager var1)
void attachOwnerSilentlyvoid attachOwnerSilently(@Nonnull TriggerVolumeManager var1)
public void clearDelayedEffectPendingvoid clearDelayedEffectPending(@Nonnull VolumeEntry.EffectEntityKey var1)
public void clearEntityRuntimeStatevoid clearEntityRuntimeState(@Nonnull UUID var1)
public void clearGroupActivationPendingvoid clearGroupActivationPending(@Nonnull String var1, int var2, @Nonnull UUID var3)
public void clearGroupActivationStatevoid clearGroupActivationState(@Nonnull String var1)
public void clearVolumeActivationPendingvoid clearVolumeActivationPending(int var1, @Nonnull UUID var2)
void detachOwnervoid detachOwner()
void expandTagsvoid expandTags()
for for(TriggerCondition var5 : var1)
for for(TriggerEffect var5 : var1)
for for(TriggerEffect var5 : var1)
for for(TriggerRule var5 : var1)
public float getActivationDelayfloat getActivationDelay()
public float getCooldownfloat getCooldown()
public boolean hasTagboolean hasTag(int var1)
if if(var5 != null)
if if(var5 != null)
if if(var5 != null)
if if(var5 != null)
if if(this.owner != null)
if if(this.owner != null)
if if(this.enabled != var1)
if if(this.owner != null)
if if(this.cooldown <= 0.0F)
if if(this.cooldownMode != CooldownMode.TOTAL)
if if(var6 == Long.MIN_VALUE)
if if(this.cooldownMode == CooldownMode.TOTAL)
public boolean isCancelDelayedEffectsOnExitboolean isCancelDelayedEffectsOnExit()
public boolean isEnabledboolean isEnabled()
public boolean isExpiredboolean isExpired(@Nonnull Instant var1)
public boolean isFromWorldGenboolean isFromWorldGen()
public boolean isGroupActivatedboolean isGroupActivated(@Nonnull String var1, int var2, @Nonnull UUID var3)
public boolean isKeepLoadedboolean isKeepLoaded()
public boolean isOnCooldownboolean isOnCooldown(@Nonnull UUID var1, long var2)
public boolean isPendingDestroyboolean isPendingDestroy()
public boolean isRotateEffectsOnPasteboolean isRotateEffectsOnPaste()
public boolean isRulesActiveboolean isRulesActive()
public boolean isVolumeActivatedboolean isVolumeActivated(int var1, @Nonnull UUID var2)
public boolean markDelayedEffectPendingboolean markDelayedEffectPending(@Nonnull VolumeEntry.EffectEntityKey var1)
public void markGroupActivatedvoid markGroupActivated(@Nonnull String var1, int var2, @Nonnull UUID var3)
public boolean markGroupActivationPendingboolean markGroupActivationPending(@Nonnull String var1, int var2, @Nonnull UUID var3)
public boolean markGroupTickRejectionFiredboolean markGroupTickRejectionFired(@Nonnull String var1, int var2, @Nonnull UUID var3)
public void markPendingDestroyvoid markPendingDestroy()
public void markVolumeActivatedvoid markVolumeActivated(int var1, @Nonnull UUID var2)
public boolean markVolumeActivationPendingboolean markVolumeActivationPending(int var1, @Nonnull UUID var2)
public boolean markVolumeTickRejectionFiredboolean markVolumeTickRejectionFired(int var1, @Nonnull UUID var2)
public void recordActivationvoid recordActivation(@Nonnull UUID var1, long var2)
public void setActivationDelayvoid setActivationDelay(float var1)
public void setCancelDelayedEffectsOnExitvoid setCancelDelayedEffectsOnExit(boolean var1)
public void setColorvoid setColor(@Nullable Vector3f var1)
public void setConditionTimingvoid setConditionTiming(@Nonnull ConditionTiming var1)
public void setCooldownvoid setCooldown(float var1)
public void setCooldownModevoid setCooldownMode(@Nonnull CooldownMode var1)
public void setEffectAssetRefvoid setEffectAssetRef(@Nullable String var1)
public void setEnabledvoid setEnabled(boolean var1)
public void setExpandedTagIndexesvoid setExpandedTagIndexes(@Nonnull IntSet var1)
public void setExpiresAtvoid setExpiresAt(@Nullable Instant var1)
public void setFromWorldGenvoid setFromWorldGen(boolean var1)
public void setGroupIdvoid setGroupId(@Nullable String var1)
public void setIdvoid setId(@Nonnull String var1)
public void setKeepLoadedvoid setKeepLoaded(boolean var1)
public void setNamevoid setName(@Nullable String var1)
public void setPositionvoid setPosition(@Nonnull Vector3d var1)
public void setProjectileSourcevoid setProjectileSource(@Nonnull ProjectileSource var1)
public void setRejectionDelayModevoid setRejectionDelayMode(@Nonnull RejectionDelayMode var1)
public void setRotateEffectsOnPastevoid setRotateEffectsOnPaste(boolean var1)
public void setRulesActivevoid setRulesActive(boolean var1)
public void setShapevoid setShape(@Nonnull TriggerVolumeShape var1)
public void setTagsvoid setTags(@Nonnull Map<String, String> var1)
public void setWorldNamevoid setWorldName(@Nonnull String var1)

Исходный код

Показать/скрыть
class="kw">package com.hypixel.hytale.builtin.triggervolumes.manager;

class="kw">import com.hypixel.hytale.assetstore.AssetRegistry;
class="kw">import com.hypixel.hytale.builtin.triggervolumes.EntityTargetType;
class="kw">import com.hypixel.hytale.builtin.triggervolumes.effect.TriggerCondition;
class="kw">import com.hypixel.hytale.builtin.triggervolumes.effect.TriggerEffect;
class="kw">import com.hypixel.hytale.builtin.triggervolumes.effect.TriggerRule;
class="kw">import com.hypixel.hytale.builtin.triggervolumes.effect.TriggerVolumeCodecs;
class="kw">import com.hypixel.hytale.builtin.triggervolumes.shape.BoxShape;
class="kw">import com.hypixel.hytale.builtin.triggervolumes.shape.TriggerVolumeShape;
class="kw">import com.hypixel.hytale.codec.Codec;
class="kw">import com.hypixel.hytale.codec.KeyedCodec;
class="kw">import com.hypixel.hytale.codec.builder.BuilderCodec;
class="kw">import com.hypixel.hytale.codec.codecs.EnumCodec;
class="kw">import com.hypixel.hytale.codec.codecs.array.ArrayCodec;
class="kw">import com.hypixel.hytale.component.Ref;
class="kw">import com.hypixel.hytale.math.vector.Vector3dUtil;
class="kw">import com.hypixel.hytale.math.vector.Vector3fUtil;
class="kw">import com.hypixel.hytale.server.core.universe.world.storage.EntityStore;
class="kw">import it.unimi.dsi.fastutil.ints.IntOpenHashSet;
class="kw">import it.unimi.dsi.fastutil.ints.IntSet;
class="kw">import it.unimi.dsi.fastutil.ints.IntSets;
class="kw">import it.unimi.dsi.fastutil.objects.Object2LongMap;
class="kw">import it.unimi.dsi.fastutil.objects.Object2LongOpenHashMap;
class="kw">import java.time.Instant;
class="kw">import java.util.ArrayList;
class="kw">import java.util.Collections;
class="kw">import java.util.EnumSet;
class="kw">import java.util.HashMap;
class="kw">import java.util.HashSet;
class="kw">import java.util.LinkedHashMap;
class="kw">import java.util.List;
class="kw">import java.util.Locale;
class="kw">import java.util.Map;
class="kw">import java.util.Set;
class="kw">import java.util.UUID;
class="kw">import java.util.Map.Entry;
class="kw">import javax.annotation.Nonnull;
class="kw">import javax.annotation.Nullable;
class="kw">import org.joml.Vector3d;
class="kw">import org.joml.Vector3f;

class="kw">public class VolumeEntry {
   @Nonnull
   class="kw">public class="kw">static class="kw">final BuilderCodec<VolumeEntry> CODEC = BuilderCodec.builder(VolumeEntry.class, VolumeEntry::new)
      .append(new KeyedCodec<>("Position", Vector3dUtil.CODEC), (var0, var1) -> var0.position = var1, var0 -> var0.position)
      .add()
      .append(new KeyedCodec<>("Shape", TriggerVolumeShape.CODEC), (var0, var1) -> var0.shape = var1, var0 -> var0.shape)
      .add()
      .append(new KeyedCodec<>("EffectAsset", Codec.STRING, false), (var0, var1) -> var0.effectAssetRef = var1, var0 -> var0.effectAssetRef)
      .add()
      .append(new KeyedCodec<>("Conditions", TriggerVolumeCodecs.TOLERANT_CONDITIONS, false), (var0, var1) -> {
         for (TriggerCondition var5 : var1) {
            if (var5 != null) {
               var0.conditions.add(var5);
            }
         }
      }, var0 -> var0.effectAssetRef == null && !var0.conditions.isEmpty() ? var0.conditions.toArray(TriggerCondition[]::new) : null)
      .add()
      .append(new KeyedCodec<>("Effects", TriggerVolumeCodecs.TOLERANT_EFFECTS, false), (var0, var1) -> {
         for (TriggerEffect var5 : var1) {
            if (var5 != null) {
               var0.effects.add(var5);
            }
         }
      }, var0 -> var0.effectAssetRef == null && !var0.effects.isEmpty() ? var0.effects.toArray(TriggerEffect[]::new) : null)
      .add()
      .append(new KeyedCodec<>("RejectionEffects", TriggerVolumeCodecs.TOLERANT_EFFECTS, false), (var0, var1) -> {
         for (TriggerEffect var5 : var1) {
            if (var5 != null) {
               var0.rejectionEffects.add(var5);
            }
         }
      }, var0 -> var0.effectAssetRef == null && !var0.rejectionEffects.isEmpty() ? var0.rejectionEffects.toArray(TriggerEffect[]::new) : null)
      .add()
      .append(new KeyedCodec<>("Rules", TriggerVolumeCodecs.TOLERANT_RULES, false), (var0, var1) -> {
         for (TriggerRule var5 : var1) {
            if (var5 != null) {
               var0.rules.add(var5);
            }
         }
      }, var0 -> var0.rules.isEmpty() ? null : var0.rules.toArray(TriggerRule[]::new))
      .add()
      .append(new KeyedCodec<>("RulesActive", Codec.BOOLEAN, false), (var0, var1) -> var0.rulesActive = var1, var0 -> var0.rulesActive ? null : Boolean.FALSE)
      .add()
      .append(
         new KeyedCodec<>("ConditionTiming", new EnumCodec<>(ConditionTiming.class), false),
         (var0, var1) -> var0.conditionTiming = var1,
         var0 -> var0.conditionTiming != ConditionTiming.AFTER_VOLUME_DELAY ? var0.conditionTiming : null
      )
      .add()
      .append(
         new KeyedCodec<>("RejectionDelayMode", new EnumCodec<>(RejectionDelayMode.class, EnumCodec.EnumStyle.LEGACY), false),
         (var0, var1) -> var0.rejectionDelayMode = var1,
         var0 -> var0.rejectionDelayMode != RejectionDelayMode.USE_VOLUME_DELAY ? var0.rejectionDelayMode : null
      )
      .add()
      .append(new KeyedCodec<>("TargetTypes", new ArrayCodec<>(new EnumCodec<>(EntityTargetType.class), EntityTargetType[]::new), false), (var0, var1) -> {
         var0.targetTypes.clear();
         Collections.addAll(var0.targetTypes, var1);
      }, var0 -> var0.targetTypes.isEmpty() ? null : var0.targetTypes.toArray(EntityTargetType[]::new))
      .add()
      .append(
         new KeyedCodec<>("ProjectileSource", new EnumCodec<>(ProjectileSource.class), false),
         (var0, var1) -> var0.projectileSource = var1 != null ? var1 : ProjectileSource.SHOOTER,
         var0 -> var0.projectileSource != ProjectileSource.SHOOTER ? var0.projectileSource : null
      )
      .add()
      .append(new KeyedCodec<>("Enabled", Codec.BOOLEAN, false), (var0, var1) -> var0.enabled = var1, var0 -> var0.enabled)
      .add()
      .append(new KeyedCodec<>("GroupId", Codec.STRING, false), (var0, var1) -> var0.groupId = var1, var0 -> var0.groupId)
      .add()
      .append(new KeyedCodec<>("Color", Vector3fUtil.CODEC, false), (var0, var1) -> var0.color = var1, var0 -> var0.color)
      .add()
      .append(new KeyedCodec<>("KeepLoaded", Codec.BOOLEAN, false), (var0, var1) -> var0.keepLoaded = var1, var0 -> var0.keepLoaded)
      .add()
      .append(
         new KeyedCodec<>("RotateEffectsOnPaste", Codec.BOOLEAN, false),
         (var0, var1) -> var0.rotateEffectsOnPaste = var1,
         var0 -> var0.rotateEffectsOnPaste ? null : Boolean.FALSE
      )
      .add()
      .append(
         new KeyedCodec<>("ActivationDelay", Codec.FLOAT, false),
         (var0, var1) -> var0.activationDelay = var1,
         var0 -> var0.activationDelay > 0.0F ? var0.activationDelay : null
      )
      .add()
      .append(
         new KeyedCodec<>("CancelDelayedOnExit", Codec.BOOLEAN, false),
         (var0, var1) -> var0.cancelDelayedEffectsOnExit = var1,
         var0 -> var0.cancelDelayedEffectsOnExit ? Boolean.TRUE : null
      )
      .add()
      .append(new KeyedCodec<>("Cooldown", Codec.FLOAT, false), (var0, var1) -> var0.cooldown = var1, var0 -> var0.cooldown > 0.0F ? var0.cooldown : null)
      .add()
      .append(new KeyedCodec<>("CooldownMode", Codec.STRING, false), (var0, var1) -> {
         try {
            var0.cooldownMode = CooldownMode.valueOf(var1.toUpperCase(Locale.ROOT));
         } catch (IllegalArgumentException var3) {
         }
      }, var0 -> var0.cooldownMode != CooldownMode.PER_ENTITY ? var0.cooldownMode.name() : null)
      .add()
      .append(new KeyedCodec<>("Tags", TriggerVolumeCodecs.TAGS, false), VolumeEntry::setTags, var0 -> var0.rawTags.isEmpty() ? null : var0.rawTags)
      .add()
      .append(new KeyedCodec<>("FromWorldGen", Codec.BOOLEAN, false), (var0, var1) -> var0.fromWorldGen = var1, var0 -> var0.fromWorldGen ? Boolean.TRUE : null)
      .add()
      .append(new KeyedCodec<>("ExpiresAt", Codec.INSTANT, false), (var0, var1) -> var0.expiresAt = var1, var0 -> var0.expiresAt)
      .add()
      .append(new KeyedCodec<>("Name", Codec.STRING, false), (var0, var1) -> var0.name = var1, var0 -> var0.name)
      .add()
      .build();
   @Nonnull
   class="kw">private String volumeId = "";
   @Nullable
   class="kw">private String name;
   @Nonnull
   class="kw">private String worldName = "";
   @Nonnull
   class="kw">private Vector3d position = new Vector3d();
   @Nonnull
   class="kw">private TriggerVolumeShape shape = new BoxShape();
   @Nonnull
   class="kw">private class="kw">final List<TriggerCondition> conditions;
   @Nonnull
   class="kw">private class="kw">final List<TriggerEffect> effects;
   @Nonnull
   class="kw">private class="kw">final List<TriggerEffect> rejectionEffects;
   @Nonnull
   class="kw">private class="kw">final List<TriggerRule> rules = new ArrayList<>();
   class="kw">private boolean rulesActive = true;
   @Nonnull
   class="kw">private class="kw">final Set<EntityTargetType> targetTypes;
   @Nonnull
   class="kw">private ProjectileSource projectileSource = ProjectileSource.SHOOTER;
   @Nonnull
   class="kw">private ConditionTiming conditionTiming = ConditionTiming.AFTER_VOLUME_DELAY;
   @Nonnull
   class="kw">private RejectionDelayMode rejectionDelayMode = RejectionDelayMode.USE_VOLUME_DELAY;
   class="kw">private boolean enabled = true;
   class="kw">private boolean keepLoaded;
   class="kw">private boolean rotateEffectsOnPaste = true;
   class="kw">private boolean fromWorldGen;
   class="kw">private boolean cancelDelayedEffectsOnExit;
   class="kw">private float activationDelay;
   class="kw">private float cooldown;
   @Nonnull
   class="kw">private CooldownMode cooldownMode = CooldownMode.PER_ENTITY;
   class="kw">private class="kw">transient boolean pendingDestroy;
   @Nullable
   class="kw">private class="kw">transient TriggerVolumeManager owner;
   class="kw">private class="kw">transient long lastGlobalActivationNanos;
   class="kw">private class="kw">final class="kw">transient Object2LongOpenHashMap<UUID> lastEntityActivationNanos = new Object2LongOpenHashMap();
   @Nullable
   class="kw">private String effectAssetRef;
   @Nullable
   class="kw">private String groupId;
   @Nullable
   class="kw">private Vector3f color;
   @Nullable
   class="kw">private Instant expiresAt;
   @Nonnull
   class="kw">private Map<String, String> rawTags = Collections.emptyMap();
   @Nonnull
   class="kw">private IntSet expandedTagIndexes = IntSets.EMPTY_SET;
   class="kw">private class="kw">final Map<UUID, Ref<EntityStore>> trackedEntities = new HashMap<>();
   class="kw">private class="kw">final Object2LongOpenHashMap<VolumeEntry.EffectEntityKey> lastFireTimes = new Object2LongOpenHashMap();
   class="kw">private class="kw">final Set<VolumeEntry.EntryEntityKey> activatedEntities = new HashSet<>();
   class="kw">private class="kw">final Set<VolumeEntry.EntryEntityKey> volumeTickRejectionsFired = new HashSet<>();
   class="kw">private class="kw">final Set<VolumeEntry.EntryEntityKey> pendingVolumeActivations = new HashSet<>();
   class="kw">private class="kw">final Set<VolumeEntry.GroupEntityKey> activatedGroups = new HashSet<>();
   class="kw">private class="kw">final Set<VolumeEntry.GroupEntityKey> groupTickRejectionsFired = new HashSet<>();
   class="kw">private class="kw">final Set<VolumeEntry.GroupEntityKey> pendingGroupActivations = new HashSet<>();
   class="kw">private class="kw">final Set<VolumeEntry.EffectEntityKey> pendingDelayedEffects = new HashSet<>();

   VolumeEntry() {
      this.conditions = new ArrayList<>();
      this.effects = new ArrayList<>();
      this.rejectionEffects = new ArrayList<>();
      this.targetTypes = EnumSet.of(EntityTargetType.PLAYER);
   }

   class="kw">public VolumeEntry(
      @Nonnull String var1,
      @Nonnull String var2,
      @Nonnull Vector3d var3,
      @Nonnull TriggerVolumeShape var4,
      @Nonnull List<TriggerEffect> var5,
      @Nonnull Set<EntityTargetType> var6,
      boolean var7
   ) {
      this.volumeId = var1;
      this.worldName = var2;
      this.position = var3;
      this.shape = var4;
      this.conditions = new ArrayList<>();
      this.effects = var5;
      this.rejectionEffects = new ArrayList<>();
      this.targetTypes = var6;
      this.enabled = var7;
   }

   class="kw">public void setId(@Nonnull String var1) {
      this.volumeId = var1;
   }

   class="kw">public void setWorldName(@Nonnull String var1) {
      this.worldName = var1;
   }

   @Nonnull
   class="kw">public String getId() {
      class="kw">return this.volumeId;
   }

   @Nullable
   class="kw">public String getName() {
      class="kw">return this.name;
   }

   class="kw">public void setName(@Nullable String var1) {
      this.name = var1;
   }

   @Nonnull
   class="kw">public String getWorldName() {
      class="kw">return this.worldName;
   }

   void attachOwner(@Nonnull TriggerVolumeManager var1) {
      this.owner = var1;
      var1.onVolumeAttached(this);
   }

   void attachOwnerSilently(@Nonnull TriggerVolumeManager var1) {
      this.owner = var1;
   }

   void detachOwner() {
      this.owner = null;
   }

   @Nonnull
   class="kw">public Vector3d getPosition() {
      class="kw">return this.position;
   }

   class="kw">public void setPosition(@Nonnull Vector3d var1) {
      SpatialSnapshot var2 = this.owner != null ? SpatialSnapshot.of(this) : null;
      this.position = var1;
      if (this.owner != null) {
         this.owner.onVolumeSpatialChanged(this, var2);
      }
   }

   @Nonnull
   class="kw">public TriggerVolumeShape getShape() {
      class="kw">return this.shape;
   }

   class="kw">public void setShape(@Nonnull TriggerVolumeShape var1) {
      SpatialSnapshot var2 = this.owner != null ? SpatialSnapshot.of(this) : null;
      this.shape = var1;
      if (this.owner != null) {
         this.owner.onVolumeSpatialChanged(this, var2);
      }
   }

   @Nonnull
   class="kw">public List<TriggerEffect> getEffects() {
      class="kw">return this.effects;
   }

   @Nonnull
   class="kw">public List<TriggerCondition> getConditions() {
      class="kw">return this.conditions;
   }

   @Nonnull
   class="kw">public List<TriggerEffect> getRejectionEffects() {
      class="kw">return this.rejectionEffects;
   }

   @Nonnull
   class="kw">public List<TriggerRule> getRules() {
      class="kw">return this.rules;
   }

   class="kw">public boolean isRulesActive() {
      class="kw">return this.rulesActive;
   }

   class="kw">public void setRulesActive(boolean var1) {
      this.rulesActive = var1;
   }

   @Nonnull
   class="kw">public ConditionTiming getConditionTiming() {
      class="kw">return this.conditionTiming;
   }

   class="kw">public void setConditionTiming(@Nonnull ConditionTiming var1) {
      this.conditionTiming = var1;
   }

   @Nonnull
   class="kw">public RejectionDelayMode getRejectionDelayMode() {
      class="kw">return this.rejectionDelayMode;
   }

   class="kw">public void setRejectionDelayMode(@Nonnull RejectionDelayMode var1) {
      this.rejectionDelayMode = var1;
   }

   @Nonnull
   class="kw">public Set<EntityTargetType> getTargetTypes() {
      class="kw">return this.targetTypes;
   }

   @Nonnull
   class="kw">public ProjectileSource getProjectileSource() {
      class="kw">return this.projectileSource;
   }

   class="kw">public void setProjectileSource(@Nonnull ProjectileSource var1) {
      this.projectileSource = var1;
   }

   class="kw">public boolean isEnabled() {
      class="kw">return this.enabled;
   }

   class="kw">public void setEnabled(boolean var1) {
      if (this.enabled != var1) {
         SpatialSnapshot var2 = this.owner != null ? SpatialSnapshot.of(this) : null;
         this.enabled = var1;
         if (this.owner != null) {
            this.owner.onVolumeEnabledChanged(this, var2);
         }
      }
   }

   class="kw">public boolean isKeepLoaded() {
      class="kw">return this.keepLoaded;
   }

   class="kw">public void setKeepLoaded(boolean var1) {
      this.keepLoaded = var1;
   }

   class="kw">public boolean isRotateEffectsOnPaste() {
      class="kw">return this.rotateEffectsOnPaste;
   }

   class="kw">public void setRotateEffectsOnPaste(boolean var1) {
      this.rotateEffectsOnPaste = var1;
   }

   class="kw">public boolean isFromWorldGen() {
      class="kw">return this.fromWorldGen;
   }

   class="kw">public void setFromWorldGen(boolean var1) {
      this.fromWorldGen = var1;
   }

   class="kw">public boolean isCancelDelayedEffectsOnExit() {
      class="kw">return this.cancelDelayedEffectsOnExit;
   }

   class="kw">public void setCancelDelayedEffectsOnExit(boolean var1) {
      this.cancelDelayedEffectsOnExit = var1;
   }

   class="kw">public float getActivationDelay() {
      class="kw">return this.activationDelay;
   }

   class="kw">public void setActivationDelay(float var1) {
      this.activationDelay = var1;
   }

   class="kw">public float getCooldown() {
      class="kw">return this.cooldown;
   }

   class="kw">public void setCooldown(float var1) {
      this.cooldown = var1;
   }

   @Nonnull
   class="kw">public CooldownMode getCooldownMode() {
      class="kw">return this.cooldownMode;
   }

   class="kw">public void setCooldownMode(@Nonnull CooldownMode var1) {
      this.cooldownMode = var1;
   }

   class="kw">public boolean isOnCooldown(@Nonnull UUID var1, long var2) {
      if (this.cooldown <= 0.0F) {
         class="kw">return false;
      }

      long var4 = (long)(this.cooldown * 1.0E9F);
      if (this.cooldownMode != CooldownMode.TOTAL) {
         long var6 = this.lastEntityActivationNanos.getOrDefault(var1, Long.MIN_VALUE);
         if (var6 == Long.MIN_VALUE) {
            class="kw">return false;
         } else if (var2 - var6 >= var4) {
            this.lastEntityActivationNanos.removeLong(var1);
            class="kw">return false;
         } else {
            class="kw">return true;
         }
      } else {
         class="kw">return this.lastGlobalActivationNanos != 0L && var2 - this.lastGlobalActivationNanos < var4;
      }
   }

   class="kw">public void recordActivation(@Nonnull UUID var1, long var2) {
      if (!(this.cooldown <= 0.0F)) {
         if (this.cooldownMode == CooldownMode.TOTAL) {
            this.lastGlobalActivationNanos = var2;
         } else {
            this.lastEntityActivationNanos.put(var1, var2);
         }
      }
   }

   class="kw">public boolean isPendingDestroy() {
      class="kw">return this.pendingDestroy;
   }

   class="kw">public void markPendingDestroy() {
      this.pendingDestroy = true;
   }

   @Nullable
   class="kw">public Instant getExpiresAt() {
      class="kw">return this.expiresAt;
   }

   class="kw">public void setExpiresAt(@Nullable Instant var1) {
      this.expiresAt = var1;
   }

   class="kw">public boolean isExpired(@Nonnull Instant var1) {
      class="kw">return this.expiresAt != null && var1.isAfter(this.expiresAt);
   }

   @Nullable
   class="kw">public String getEffectAssetRef() {
      class="kw">return this.effectAssetRef;
   }

   class="kw">public void setEffectAssetRef(@Nullable String var1) {
      this.effectAssetRef = var1;
   }

   @Nullable
   class="kw">public String getGroupId() {
      class="kw">return this.groupId;
   }

   class="kw">public void setGroupId(@Nullable String var1) {
      this.groupId = var1;
   }

   @Nullable
   class="kw">public Vector3f getColor() {
      class="kw">return this.color;
   }

   class="kw">public void setColor(@Nullable Vector3f var1) {
      this.color = var1;
   }

   @Nonnull
   class="kw">public Map<String, String> getRawTags() {
      class="kw">return this.rawTags;
   }

   class="kw">public void setTags(@Nonnull Map<String, String> var1) {
      this.rawTags = normalizeTags(var1);
      this.expandTags();
   }

   @Nonnull
   class="kw">public IntSet getExpandedTagIndexes() {
      class="kw">return this.expandedTagIndexes;
   }

   class="kw">public void setExpandedTagIndexes(@Nonnull IntSet var1) {
      this.expandedTagIndexes = var1;
   }

   class="kw">public boolean hasTag(int var1) {
      class="kw">return this.expandedTagIndexes.contains(var1);
   }

   void expandTags() {
      if (this.rawTags.isEmpty()) {
         this.expandedTagIndexes = IntSets.EMPTY_SET;
      } else {
         IntOpenHashSet var1 = new IntOpenHashSet();

         for (Entry var3 : this.rawTags.entrySet()) {
            String var4 = var3.getKey();
            var1.add(AssetRegistry.getOrCreateTagIndex(var4));
            String var5 = var3.getValue();
            var1.add(AssetRegistry.getOrCreateTagIndex(var5));
            var1.add(AssetRegistry.getOrCreateTagIndex(var4 + "=" + var5));
         }

         this.expandedTagIndexes = IntSets.unmodifiable(var1);
      }
   }

   @Nonnull
   class="kw">private class="kw">static Map<String, String> normalizeTags(@Nonnull Map<String, String> var0) {
      if (var0.isEmpty()) {
         class="kw">return Collections.emptyMap();
      }

      LinkedHashMap var1 = new LinkedHashMap<>();

      for (Entry var3 : var0.entrySet()) {
         String var4 = var3.getKey().trim();
         if (!var4.isEmpty()) {
            var1.put(var4, TriggerVolumeCodecs.TaggedValue.normalize(var3.getValue()));
         }
      }

      class="kw">return var1.isEmpty() ? Collections.emptyMap() : Collections.unmodifiableMap(var1);
   }

   @Nonnull
   class="kw">public Map<UUID, Ref<EntityStore>> getTrackedEntities() {
      class="kw">return this.trackedEntities;
   }

   @Nonnull
   class="kw">public Object2LongMap<VolumeEntry.EffectEntityKey> getLastFireTimes() {
      class="kw">return this.lastFireTimes;
   }

   class="kw">public boolean isVolumeActivated(int var1, @Nonnull UUID var2) {
      class="kw">return this.activatedEntities.contains(new VolumeEntry.EntryEntityKey(var1, var2));
   }

   class="kw">public void markVolumeActivated(int var1, @Nonnull UUID var2) {
      this.activatedEntities.add(new VolumeEntry.EntryEntityKey(var1, var2));
   }

   class="kw">public boolean markVolumeActivationPending(int var1, @Nonnull UUID var2) {
      class="kw">return this.pendingVolumeActivations.add(new VolumeEntry.EntryEntityKey(var1, var2));
   }

   class="kw">public void clearVolumeActivationPending(int var1, @Nonnull UUID var2) {
      this.pendingVolumeActivations.remove(new VolumeEntry.EntryEntityKey(var1, var2));
   }

   class="kw">public boolean markVolumeTickRejectionFired(int var1, @Nonnull UUID var2) {
      class="kw">return this.volumeTickRejectionsFired.add(new VolumeEntry.EntryEntityKey(var1, var2));
   }

   class="kw">public boolean isGroupActivated(@Nonnull String var1, int var2, @Nonnull UUID var3) {
      class="kw">return this.activatedGroups.contains(new VolumeEntry.GroupEntityKey(var1, var2, var3));
   }

   class="kw">public void markGroupActivated(@Nonnull String var1, int var2, @Nonnull UUID var3) {
      this.activatedGroups.add(new VolumeEntry.GroupEntityKey(var1, var2, var3));
   }

   class="kw">public boolean markGroupActivationPending(@Nonnull String var1, int var2, @Nonnull UUID var3) {
      class="kw">return this.pendingGroupActivations.add(new VolumeEntry.GroupEntityKey(var1, var2, var3));
   }

   class="kw">public void clearGroupActivationPending(@Nonnull String var1, int var2, @Nonnull UUID var3) {
      this.pendingGroupActivations.remove(new VolumeEntry.GroupEntityKey(var1, var2, var3));
   }

   class="kw">public void clearGroupActivationState(@Nonnull String var1) {
      this.activatedGroups.removeIf(var1x -> var1x.groupId().equals(var1));
      this.groupTickRejectionsFired.removeIf(var1x -> var1x.groupId().equals(var1));
      this.pendingGroupActivations.removeIf(var1x -> var1x.groupId().equals(var1));
   }

   class="kw">public boolean markGroupTickRejectionFired(@Nonnull String var1, int var2, @Nonnull UUID var3) {
      class="kw">return this.groupTickRejectionsFired.add(new VolumeEntry.GroupEntityKey(var1, var2, var3));
   }

   class="kw">public boolean markDelayedEffectPending(@Nonnull VolumeEntry.EffectEntityKey var1) {
      class="kw">return this.pendingDelayedEffects.add(var1);
   }

   class="kw">public void clearDelayedEffectPending(@Nonnull VolumeEntry.EffectEntityKey var1) {
      this.pendingDelayedEffects.remove(var1);
   }

   class="kw">public void clearEntityRuntimeState(@Nonnull UUID var1) {
      this.activatedEntities.removeIf(var1x -> var1x.entityId().equals(var1));
      this.volumeTickRejectionsFired.removeIf(var1x -> var1x.entityId().equals(var1));
      this.pendingVolumeActivations.removeIf(var1x -> var1x.entityId().equals(var1));
      this.activatedGroups.removeIf(var1x -> var1x.entityId().equals(var1));
      this.groupTickRejectionsFired.removeIf(var1x -> var1x.entityId().equals(var1));
      this.pendingGroupActivations.removeIf(var1x -> var1x.entityId().equals(var1));
      this.pendingDelayedEffects.removeIf(var1x -> var1x.entityId().equals(var1));
      this.lastFireTimes.object2LongEntrySet().removeIf(var1x -> ((VolumeEntry.EffectEntityKey)var1x.getKey()).entityId().equals(var1));
   }

   class="kw">public enum EffectBucket {
      VOLUME,
      VOLUME_REJECTION,
      GROUP,
      GROUP_REJECTION;

      EffectBucket() {
      }
   }

   class="kw">public record EffectEntityKey(@Nonnull VolumeEntry.EffectBucket bucket, int effectIndex, @Nonnull UUID entityId) {
      class="kw">public EffectEntityKey {
      }
   }

   class="kw">public record EntryEntityKey(int entry, @Nonnull UUID entityId) {
      class="kw">public EntryEntityKey {
      }
   }

   class="kw">public record GroupEntityKey(@Nonnull String groupId, int entry, @Nonnull UUID entityId) {
      class="kw">public GroupEntityKey {
      }
   }
}