Changed chest spawn animation
This commit is contained in:
parent
4a803c1482
commit
2bb8023b47
@ -22,7 +22,7 @@ public class UnlockCosmeticsCommand extends CommandBase<GadgetManager>
|
||||
|
||||
public UnlockCosmeticsCommand(GadgetManager plugin)
|
||||
{
|
||||
super(plugin, Rank.SNR_MODERATOR, "unlockCosmetics");
|
||||
super(plugin, Rank.JNR_DEV, "unlockCosmetics");
|
||||
_plugin = plugin;
|
||||
}
|
||||
|
||||
@ -85,7 +85,7 @@ public class UnlockCosmeticsCommand extends CommandBase<GadgetManager>
|
||||
}
|
||||
}
|
||||
}
|
||||
UtilPlayer.message(caller, F.main("Unlock Cosmetics", "Added" + added + F.elem(" " + gadgetType.getCategoryType()) + UtilText.plural(" item", added) + "!"));
|
||||
UtilPlayer.message(caller, F.main("Unlock Cosmetics", "Added " + added + F.elem(" " + gadgetType.getCategoryType()) + UtilText.plural(" item", added) + "!"));
|
||||
}
|
||||
|
||||
private void addMounts(Player caller)
|
||||
|
@ -80,7 +80,7 @@ public enum TreasureStyle
|
||||
MINESTRIKE(
|
||||
ParticleType.FIREWORKS_SPARK,
|
||||
ParticleType.FIREWORKS_SPARK,
|
||||
ParticleType.FIREWORKS_SPARK,
|
||||
ParticleType.INSTANT_SPELL,
|
||||
Sound.EXPLODE,
|
||||
Sound.EXPLODE
|
||||
);
|
||||
|
@ -113,10 +113,10 @@ public class ChestSpawnAnimation extends Animation
|
||||
{
|
||||
float scale = (float)((double)(ANIMATION_DURATION - getTicks()) / (double)ANIMATION_DURATION);
|
||||
|
||||
//Move Paticle Forwards
|
||||
//Move Particle Forwards
|
||||
_particleLocation.add(_particleDirection);
|
||||
|
||||
//Play Particels
|
||||
//Play Particles
|
||||
if (getTreasure().getTreasureType() == TreasureType.OLD)
|
||||
{
|
||||
UtilParticle.PlayParticle(getTreasure().getTreasureType().getStyle().getSecondaryParticle(), _centerLocation, 0.1f, 0.1f, 0.1f, 0, 1,
|
||||
@ -134,7 +134,7 @@ public class ChestSpawnAnimation extends Animation
|
||||
UtilParticle.PlayParticle(getTreasure().getTreasureType().getStyle().getSecondaryParticle(), newLoc, 0f, 0f, 0f, 0, 1,
|
||||
ViewDist.NORMAL, UtilServer.getPlayers());
|
||||
}
|
||||
else if (getTreasure().getTreasureType() == TreasureType.MYTHICAL)
|
||||
else if (getTreasure().getTreasureType() == TreasureType.MYTHICAL || getTreasure().getTreasureType() == TreasureType.MINESTRIKE)
|
||||
{
|
||||
float y = 5 * scale;
|
||||
double width = 0.7 * ((double) getTicks() / (double) ANIMATION_DURATION);
|
||||
@ -146,9 +146,17 @@ public class ChestSpawnAnimation extends Animation
|
||||
float x = (float) (Math.sin(getTicks()/4D + lead));
|
||||
float z = (float) (Math.cos(getTicks()/4D + lead));
|
||||
|
||||
if (getTreasure().getTreasureType() == TreasureType.MYTHICAL)
|
||||
{
|
||||
UtilParticle.PlayParticle(getTreasure().getTreasureType().getStyle().getSecondaryParticle(), _centerLocation.clone().add(x * width, y, z * width), 0f, 0f, 0f, 0, 1,
|
||||
ViewDist.NORMAL, UtilServer.getPlayers());
|
||||
}
|
||||
else
|
||||
{
|
||||
ColoredParticle coloredParticle = new ColoredParticle(ParticleType.RED_DUST, new DustSpellColor(Color.YELLOW), _centerLocation.clone().add(x * width, y, z * width));
|
||||
coloredParticle.display();
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (getTreasure().getTreasureType() == TreasureType.CHRISTMAS)
|
||||
{
|
||||
@ -268,7 +276,12 @@ public class ChestSpawnAnimation extends Animation
|
||||
|
||||
if (particleType != null)
|
||||
{
|
||||
if (getTreasure().getTreasureType() != TreasureType.FREEDOM && getTreasure().getTreasureType() != TreasureType.HAUNTED
|
||||
if (getTreasure().getTreasureType() == TreasureType.MINESTRIKE)
|
||||
{
|
||||
ColoredParticle coloredParticle = new ColoredParticle(ParticleType.RED_DUST, new DustSpellColor(Color.YELLOW), _centerLocation.clone().add(0, 1, 0));
|
||||
coloredParticle.display(50);
|
||||
}
|
||||
else if (getTreasure().getTreasureType() != TreasureType.FREEDOM && getTreasure().getTreasureType() != TreasureType.HAUNTED
|
||||
|| getTreasure().getTreasureType() != TreasureType.GINGERBREAD)
|
||||
{
|
||||
UtilParticle.PlayParticle(particleType, _centerLocation, 0.2f, 0.2f, 0.2f, 0, 50,
|
||||
|
Loading…
Reference in New Issue
Block a user