Fix a few jetpack things
This commit is contained in:
parent
bf9d48d86f
commit
aca0692cec
3 changed files with 20 additions and 9 deletions
|
@ -177,12 +177,14 @@ public class ModelJetpack extends ModelBase
|
|||
GL11.glPushMatrix();
|
||||
MekanismRenderer.blendOn();
|
||||
MekanismRenderer.glowOn();
|
||||
GL11.glEnable(GL11.GL_CULL_FACE);
|
||||
GL11.glColor4f(1, 1, 1, 0.2F);
|
||||
|
||||
WingbladeL.render(size);
|
||||
WingbladeR.render(size);
|
||||
|
||||
GL11.glColor4f(1, 1, 1, 1);
|
||||
GL11.glDisable(GL11.GL_CULL_FACE);
|
||||
MekanismRenderer.glowOff();
|
||||
MekanismRenderer.blendOff();
|
||||
GL11.glPopMatrix();
|
||||
|
|
|
@ -12,6 +12,8 @@ public class JetpackSound extends Sound
|
|||
/** The TileEntity this sound is associated with. */
|
||||
public EntityPlayer player;
|
||||
|
||||
public int ticksSincePlay = 0;
|
||||
|
||||
public JetpackSound(String id, String sound, EntityPlayer entity)
|
||||
{
|
||||
super(id, sound, entity, new Vector3(entity));
|
||||
|
@ -22,7 +24,7 @@ public class JetpackSound extends Sound
|
|||
@Override
|
||||
public float getMultiplier()
|
||||
{
|
||||
return 1;
|
||||
return Math.min(1, ((float)ticksSincePlay/20F))*0.3F;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -30,6 +32,14 @@ public class JetpackSound extends Sound
|
|||
{
|
||||
return new Vector3(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void play()
|
||||
{
|
||||
super.play();
|
||||
|
||||
ticksSincePlay = 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean update(World world)
|
||||
|
@ -59,6 +69,11 @@ public class JetpackSound extends Sound
|
|||
}
|
||||
}
|
||||
|
||||
if(isPlaying)
|
||||
{
|
||||
ticksSincePlay++;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -5,10 +5,7 @@ import cpw.mods.fml.common.IPlayerTracker;
|
|||
public class CommonPlayerTracker implements IPlayerTracker
|
||||
{
|
||||
@Override
|
||||
public void onPlayerLogin(EntityPlayer player)
|
||||
{
|
||||
|
||||
}
|
||||
public void onPlayerLogin(EntityPlayer player) {}
|
||||
|
||||
@Override
|
||||
public void onPlayerLogout(EntityPlayer player)
|
||||
|
@ -17,10 +14,7 @@ public class CommonPlayerTracker implements IPlayerTracker
|
|||
}
|
||||
|
||||
@Override
|
||||
public void onPlayerChangedDimension(EntityPlayer player)
|
||||
{
|
||||
|
||||
}
|
||||
public void onPlayerChangedDimension(EntityPlayer player) {}
|
||||
|
||||
@Override
|
||||
public void onPlayerRespawn(EntityPlayer player) {}
|
||||
|
|
Loading…
Reference in a new issue