package dev.loki.loparkour.util; import dev.loki.loparkour.util.ParticleData; import org.bukkit.Particle; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; /** * Particle data holder for migration from vilib */ public class ParticleData { private final Particle particle; private final T data; private int size = 1; private double speed = 0.0; private double offsetX = 0.0; private double offsetY = 0.0; private double offsetZ = 0.0; public ParticleData(@NotNull Particle particle, @Nullable T data, int size) { this.particle = particle; this.data = data; this.size = size; } public ParticleData size(int size) { this.size = size; return this; } public ParticleData speed(double speed) { this.speed = speed; return this; } public ParticleData offsetX(double offsetX) { this.offsetX = offsetX; return this; } public ParticleData offsetY(double offsetY) { this.offsetY = offsetY; return this; } public ParticleData offsetZ(double offsetZ) { this.offsetZ = offsetZ; return this; } public Particle getParticle() { return particle; } public T getData() { return data; } public int getSize() { return size; } public double getSpeed() { return speed; } public double getOffsetX() { return offsetX; } public double getOffsetY() { return offsetY; } public double getOffsetZ() { return offsetZ; } }