Reformated
This commit is contained in:
parent
fc1da134e7
commit
60e8008cb7
416 changed files with 5772 additions and 4573 deletions
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.Particle;
|
||||
import net.minecraft.client.particle.ParticleProvider;
|
||||
|
@ -11,8 +13,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class FireflyParticle extends SimpleAnimatedParticle {
|
||||
private double preVX;
|
||||
|
@ -22,14 +22,16 @@ public class FireflyParticle extends SimpleAnimatedParticle {
|
|||
private double nextVY;
|
||||
private double nextVZ;
|
||||
|
||||
protected FireflyParticle(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
SpriteSet sprites,
|
||||
double r,
|
||||
double g,
|
||||
double b) {
|
||||
protected FireflyParticle(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
SpriteSet sprites,
|
||||
double r,
|
||||
double g,
|
||||
double b
|
||||
) {
|
||||
super(world, x, y, z, sprites, 0);
|
||||
setSprite(sprites.get(random));
|
||||
this.lifetime = MHelper.randRange(150, 300, random);
|
||||
|
@ -82,14 +84,16 @@ public class FireflyParticle extends SimpleAnimatedParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new FireflyParticle(world, x, y, z, sprites, 1, 1, 1);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,15 +10,17 @@ public class InfusionParticle extends TextureSheetParticle {
|
|||
|
||||
private final SpriteSet spriteProvider;
|
||||
|
||||
public InfusionParticle(ClientLevel clientWorld,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double velocityX,
|
||||
double velocityY,
|
||||
double velocityZ,
|
||||
float[] palette,
|
||||
SpriteSet spriteProvider) {
|
||||
public InfusionParticle(
|
||||
ClientLevel clientWorld,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double velocityX,
|
||||
double velocityY,
|
||||
double velocityZ,
|
||||
float[] palette,
|
||||
SpriteSet spriteProvider
|
||||
) {
|
||||
super(clientWorld, x, y, z, 0.0, 0.0, 0.0);
|
||||
this.setSpriteFromAge(spriteProvider);
|
||||
this.spriteProvider = spriteProvider;
|
||||
|
@ -60,14 +62,16 @@ public class InfusionParticle extends TextureSheetParticle {
|
|||
this.spriteProvider = spriteProvider;
|
||||
}
|
||||
|
||||
public Particle createParticle(InfusionParticleType particleType,
|
||||
ClientLevel clientWorld,
|
||||
double d,
|
||||
double e,
|
||||
double f,
|
||||
double g,
|
||||
double h,
|
||||
double i) {
|
||||
public Particle createParticle(
|
||||
InfusionParticleType particleType,
|
||||
ClientLevel clientWorld,
|
||||
double d,
|
||||
double e,
|
||||
double f,
|
||||
double g,
|
||||
double h,
|
||||
double i
|
||||
) {
|
||||
return new InfusionParticle(clientWorld, d, e, f, g, h, i, particleType.getPalette(), this.spriteProvider);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,11 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.ColorUtil;
|
||||
import org.betterx.betterend.registry.EndParticles;
|
||||
|
||||
import com.mojang.brigadier.StringReader;
|
||||
import com.mojang.brigadier.exceptions.CommandSyntaxException;
|
||||
import com.mojang.serialization.Codec;
|
||||
import net.minecraft.commands.arguments.item.ItemInput;
|
||||
import net.minecraft.commands.arguments.item.ItemParser;
|
||||
import net.minecraft.core.HolderLookup;
|
||||
|
@ -12,12 +18,6 @@ import net.minecraft.world.item.ItemStack;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import com.mojang.brigadier.StringReader;
|
||||
import com.mojang.brigadier.exceptions.CommandSyntaxException;
|
||||
import com.mojang.serialization.Codec;
|
||||
import org.betterx.bclib.util.ColorUtil;
|
||||
import org.betterx.betterend.registry.EndParticles;
|
||||
|
||||
public class InfusionParticleType extends ParticleType<InfusionParticleType> implements ParticleOptions {
|
||||
public static final Codec<InfusionParticleType> CODEC = ItemStack.CODEC.xmap(itemStack -> new InfusionParticleType(
|
||||
EndParticles.INFUSION,
|
||||
|
@ -26,18 +26,24 @@ public class InfusionParticleType extends ParticleType<InfusionParticleType> imp
|
|||
|
||||
@SuppressWarnings("deprecation")
|
||||
public static final ParticleOptions.Deserializer<InfusionParticleType> PARAMETERS_FACTORY = new ParticleOptions.Deserializer<InfusionParticleType>() {
|
||||
public InfusionParticleType fromCommand(ParticleType<InfusionParticleType> particleType,
|
||||
StringReader stringReader) throws CommandSyntaxException {
|
||||
public InfusionParticleType fromCommand(
|
||||
ParticleType<InfusionParticleType> particleType,
|
||||
StringReader stringReader
|
||||
) throws CommandSyntaxException {
|
||||
stringReader.expect(' ');
|
||||
ItemParser.ItemResult itemResult = ItemParser.parseForItem(HolderLookup.forRegistry(Registry.ITEM),
|
||||
stringReader);
|
||||
ItemParser.ItemResult itemResult = ItemParser.parseForItem(
|
||||
HolderLookup.forRegistry(Registry.ITEM),
|
||||
stringReader
|
||||
);
|
||||
ItemStack itemStack = new ItemInput(itemResult.item(), itemResult.nbt()).createItemStack(1, false);
|
||||
|
||||
return new InfusionParticleType(particleType, itemStack);
|
||||
}
|
||||
|
||||
public InfusionParticleType fromNetwork(ParticleType<InfusionParticleType> particleType,
|
||||
FriendlyByteBuf packetByteBuf) {
|
||||
public InfusionParticleType fromNetwork(
|
||||
ParticleType<InfusionParticleType> particleType,
|
||||
FriendlyByteBuf packetByteBuf
|
||||
) {
|
||||
return new InfusionParticleType(particleType, packetByteBuf.readItem());
|
||||
}
|
||||
};
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.*;
|
||||
import net.minecraft.core.particles.SimpleParticleType;
|
||||
|
@ -8,8 +10,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class ParticleBlackSpore extends SimpleAnimatedParticle {
|
||||
private double preVX;
|
||||
|
@ -19,14 +19,16 @@ public class ParticleBlackSpore extends SimpleAnimatedParticle {
|
|||
private double nextVY;
|
||||
private double nextVZ;
|
||||
|
||||
protected ParticleBlackSpore(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites) {
|
||||
protected ParticleBlackSpore(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites
|
||||
) {
|
||||
super(world, x, y, z, sprites, 0);
|
||||
setSprite(sprites.get(random));
|
||||
|
||||
|
@ -89,14 +91,16 @@ public class ParticleBlackSpore extends SimpleAnimatedParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new ParticleBlackSpore(world, x, y, z, 1, 1, 1, sprites);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.*;
|
||||
import net.minecraft.core.BlockPos.MutableBlockPos;
|
||||
|
@ -8,22 +10,22 @@ import net.minecraft.core.particles.SimpleParticleType;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class ParticleGeyser extends TextureSheetParticle {
|
||||
private final MutableBlockPos mut = new MutableBlockPos();
|
||||
private boolean changeDir = false;
|
||||
private boolean check = true;
|
||||
|
||||
protected ParticleGeyser(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vx,
|
||||
double vy,
|
||||
double vz,
|
||||
SpriteSet sprites) {
|
||||
protected ParticleGeyser(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vx,
|
||||
double vy,
|
||||
double vz,
|
||||
SpriteSet sprites
|
||||
) {
|
||||
super(world, x, y, z, vx, vy, vz);
|
||||
pickSprite(sprites);
|
||||
this.lifetime = MHelper.randRange(400, 800, random);
|
||||
|
@ -75,14 +77,16 @@ public class ParticleGeyser extends TextureSheetParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new ParticleGeyser(world, x, y, z, 0, 0.125, 0, sprites);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.Particle;
|
||||
import net.minecraft.client.particle.ParticleProvider;
|
||||
|
@ -11,8 +13,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class ParticleGlowingSphere extends SimpleAnimatedParticle {
|
||||
private int ticks;
|
||||
|
@ -23,14 +23,16 @@ public class ParticleGlowingSphere extends SimpleAnimatedParticle {
|
|||
private double nextVY;
|
||||
private double nextVZ;
|
||||
|
||||
protected ParticleGlowingSphere(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
SpriteSet sprites,
|
||||
double r,
|
||||
double g,
|
||||
double b) {
|
||||
protected ParticleGlowingSphere(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
SpriteSet sprites,
|
||||
double r,
|
||||
double g,
|
||||
double b
|
||||
) {
|
||||
super(world, x, y, z, sprites, 0);
|
||||
setSprite(sprites.get(random));
|
||||
this.lifetime = MHelper.randRange(150, 300, random);
|
||||
|
@ -78,14 +80,16 @@ public class ParticleGlowingSphere extends SimpleAnimatedParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new ParticleGlowingSphere(world, x, y, z, sprites, 1, 1, 1);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.Particle;
|
||||
import net.minecraft.client.particle.ParticleProvider;
|
||||
|
@ -10,19 +12,19 @@ import net.minecraft.core.particles.SimpleParticleType;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class ParticleJungleSpore extends SimpleAnimatedParticle {
|
||||
|
||||
protected ParticleJungleSpore(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
SpriteSet sprites,
|
||||
double r,
|
||||
double g,
|
||||
double b) {
|
||||
protected ParticleJungleSpore(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
SpriteSet sprites,
|
||||
double r,
|
||||
double g,
|
||||
double b
|
||||
) {
|
||||
super(world, x, y, z, sprites, 0);
|
||||
setSprite(sprites.get(random));
|
||||
this.lifetime = MHelper.randRange(150, 300, random);
|
||||
|
@ -69,14 +71,16 @@ public class ParticleJungleSpore extends SimpleAnimatedParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new ParticleJungleSpore(world, x, y, z, sprites, 1, 1, 1);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.*;
|
||||
import net.minecraft.core.particles.SimpleParticleType;
|
||||
|
@ -8,8 +10,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class ParticleSnowflake extends TextureSheetParticle {
|
||||
private int ticks;
|
||||
|
@ -20,14 +20,16 @@ public class ParticleSnowflake extends TextureSheetParticle {
|
|||
private double nextVY;
|
||||
private double nextVZ;
|
||||
|
||||
protected ParticleSnowflake(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites) {
|
||||
protected ParticleSnowflake(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites
|
||||
) {
|
||||
super(world, x, y, z, r, g, b);
|
||||
pickSprite(sprites);
|
||||
|
||||
|
@ -93,14 +95,16 @@ public class ParticleSnowflake extends TextureSheetParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new ParticleSnowflake(world, x, y, z, 1, 1, 1, sprites);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.*;
|
||||
import net.minecraft.core.particles.SimpleParticleType;
|
||||
|
@ -8,8 +10,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class ParticleSulphur extends TextureSheetParticle {
|
||||
private int ticks;
|
||||
|
@ -20,14 +20,16 @@ public class ParticleSulphur extends TextureSheetParticle {
|
|||
private double nextVY;
|
||||
private double nextVZ;
|
||||
|
||||
protected ParticleSulphur(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites) {
|
||||
protected ParticleSulphur(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites
|
||||
) {
|
||||
super(world, x, y, z, r, g, b);
|
||||
pickSprite(sprites);
|
||||
|
||||
|
@ -94,14 +96,16 @@ public class ParticleSulphur extends TextureSheetParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new ParticleSulphur(world, x, y, z, 1, 1, 1, sprites);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.interfaces.CustomColorProvider;
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
import org.betterx.betterend.registry.EndBlocks;
|
||||
|
||||
import net.minecraft.client.color.block.BlockColor;
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.*;
|
||||
|
@ -10,10 +14,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.interfaces.CustomColorProvider;
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
import org.betterx.betterend.registry.EndBlocks;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class ParticleTenaneaPetal extends TextureSheetParticle {
|
||||
private static BlockColor provider;
|
||||
|
@ -25,14 +25,16 @@ public class ParticleTenaneaPetal extends TextureSheetParticle {
|
|||
private double nextVY;
|
||||
private double nextVZ;
|
||||
|
||||
protected ParticleTenaneaPetal(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites) {
|
||||
protected ParticleTenaneaPetal(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites
|
||||
) {
|
||||
super(world, x, y, z, r, g, b);
|
||||
pickSprite(sprites);
|
||||
|
||||
|
@ -108,14 +110,16 @@ public class ParticleTenaneaPetal extends TextureSheetParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new ParticleTenaneaPetal(world, x, y, z, 1, 1, 1, sprites);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.Particle;
|
||||
import net.minecraft.client.particle.ParticleProvider;
|
||||
|
@ -11,8 +13,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
public class PaticlePortalSphere extends SimpleAnimatedParticle {
|
||||
private int ticks;
|
||||
private double preVX;
|
||||
|
@ -71,14 +71,16 @@ public class PaticlePortalSphere extends SimpleAnimatedParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new PaticlePortalSphere(world, x, y, z, sprites);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package org.betterx.betterend.particle;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
import net.minecraft.client.multiplayer.ClientLevel;
|
||||
import net.minecraft.client.particle.*;
|
||||
import net.minecraft.core.particles.SimpleParticleType;
|
||||
|
@ -8,8 +10,6 @@ import net.minecraft.util.Mth;
|
|||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
|
||||
import org.betterx.bclib.util.MHelper;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class SmaragdantParticle extends SimpleAnimatedParticle {
|
||||
private double preVX;
|
||||
|
@ -19,14 +19,16 @@ public class SmaragdantParticle extends SimpleAnimatedParticle {
|
|||
private double nextVY;
|
||||
private double nextVZ;
|
||||
|
||||
protected SmaragdantParticle(ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites) {
|
||||
protected SmaragdantParticle(
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double r,
|
||||
double g,
|
||||
double b,
|
||||
SpriteSet sprites
|
||||
) {
|
||||
super(world, x, y, z, sprites, 0);
|
||||
setSprite(sprites.get(random));
|
||||
|
||||
|
@ -89,14 +91,16 @@ public class SmaragdantParticle extends SimpleAnimatedParticle {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Particle createParticle(SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ) {
|
||||
public Particle createParticle(
|
||||
SimpleParticleType type,
|
||||
ClientLevel world,
|
||||
double x,
|
||||
double y,
|
||||
double z,
|
||||
double vX,
|
||||
double vY,
|
||||
double vZ
|
||||
) {
|
||||
return new SmaragdantParticle(world, x, y, z, 1, 1, 1, sprites);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue