9
0
mirror of https://github.com/VolmitSoftware/Iris.git synced 2025-12-25 18:19:14 +00:00

Fix spawning (pandas)

This commit is contained in:
Daniel Mills
2020-09-11 08:05:11 -04:00
parent 200e576ba8
commit be6739ecb8
2 changed files with 2 additions and 3 deletions

View File

@@ -182,7 +182,6 @@ public class IrisEffect
private final transient AtomicCache<PotionEffectType> pt = new AtomicCache<>();
private final transient AtomicCache<ChronoLatch> latch = new AtomicCache<>();
public boolean canTick()
{
return latch.aquire(() -> new ChronoLatch(interval)).flip();
@@ -245,7 +244,7 @@ public class IrisEffect
{
Location part = p.getLocation().clone().add(p.getLocation().getDirection().clone().multiply(RNG.r.i(particleDistance) + particleAway)).clone().add(p.getLocation().getDirection().clone().rotateAroundY(Math.toRadians(90)).multiply(RNG.r.d(-particleDistanceWidth, particleDistanceWidth)));
part.setY(Math.round(g.getTerrainHeight(part.getBlockX(), part.getBlockZ())) + 1);
part.setY(Math.round(g.getCarvedHeight(part.getBlockX(), part.getBlockZ(), true)) + 1);
part.add(RNG.r.d(), 0, RNG.r.d());
if(extra != 0)
{

View File

@@ -88,6 +88,6 @@ public class IrisEntityInitialSpawn
private Entity spawn100(ParallaxTerrainProvider g, Location at)
{
return getRealEntity(g).spawn(g, at, rng.aquire(() -> new RNG(g.getTarget().getSeed() + 4)));
return getRealEntity(g).spawn(g, at.clone().add(0, 1, 0), rng.aquire(() -> new RNG(g.getTarget().getSeed() + 4)));
}
}