mirror of
https://github.com/Creators-of-Create/Create.git
synced 2024-12-29 08:27:03 +01:00
Instanced Bonus
- fixed PSI actor instance not updated with recent changes
This commit is contained in:
parent
a6e86520f5
commit
18a84006ca
1 changed files with 4 additions and 3 deletions
|
@ -5,6 +5,7 @@ import com.jozufozu.flywheel.core.virtual.VirtualRenderWorld;
|
||||||
import com.simibubi.create.content.contraptions.components.structureMovement.MovementContext;
|
import com.simibubi.create.content.contraptions.components.structureMovement.MovementContext;
|
||||||
import com.simibubi.create.content.contraptions.components.structureMovement.render.ActorInstance;
|
import com.simibubi.create.content.contraptions.components.structureMovement.render.ActorInstance;
|
||||||
import com.simibubi.create.foundation.utility.AnimationTickHolder;
|
import com.simibubi.create.foundation.utility.AnimationTickHolder;
|
||||||
|
import com.simibubi.create.foundation.utility.animation.LerpedFloat;
|
||||||
|
|
||||||
public class PSIActorInstance extends ActorInstance {
|
public class PSIActorInstance extends ActorInstance {
|
||||||
|
|
||||||
|
@ -22,9 +23,9 @@ public class PSIActorInstance extends ActorInstance {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void beginFrame() {
|
public void beginFrame() {
|
||||||
PortableStorageInterfaceTileEntity psi = PortableStorageInterfaceRenderer.getTargetPSI(context);
|
LerpedFloat lf = PortableStorageInterfaceMovement.getAnimation(context);
|
||||||
instance.tick(psi != null && psi.isConnected());
|
instance.tick(lf.settled());
|
||||||
instance.beginFrame(psi == null ? 0f : psi.getExtensionDistance(AnimationTickHolder.getPartialTicks()));
|
instance.beginFrame(lf.getValue(AnimationTickHolder.getPartialTicks()));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue