mirror of
https://github.com/MineLittlePony/MineLittlePony.git
synced 2025-02-13 08:14:23 +01:00
Implement pose changes for the swimming mode
This commit is contained in:
parent
402e055112
commit
eb54809f1e
1 changed files with 10 additions and 0 deletions
|
@ -50,6 +50,16 @@ public class RenderDummyPony extends RenderDummyPlayer<DummyPony, ClientPonyMode
|
|||
protected void scale(DummyPony entity, float ticks) {
|
||||
renderPony.preRenderCallback(entity, ticks);
|
||||
|
||||
if (entity.isSwimming()) {
|
||||
if (entity.getVelocity().x < 100) {
|
||||
entity.addVelocity(100, 0, 0);
|
||||
}
|
||||
|
||||
model.getAttributes().motionPitch = 70;
|
||||
} else {
|
||||
model.getAttributes().motionPitch = 0;
|
||||
}
|
||||
|
||||
if (entity.hasVehicle()) {
|
||||
GlStateManager.translated(0, entity.getHeightOffset(), 0);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue