Implement SpectralArrow#getGlowingTicks and SpectralArrow#setGlowingTicks(int)

This commit is contained in:
Matthew 2016-03-17 15:00:24 -04:00 committed by md_5
parent f332350969
commit f09f7d8754
2 changed files with 21 additions and 0 deletions

View File

@ -0,0 +1,11 @@
--- a/net/minecraft/server/EntitySpectralArrow.java
+++ b/net/minecraft/server/EntitySpectralArrow.java
@@ -2,7 +2,7 @@
public class EntitySpectralArrow extends EntityArrow {
- private int f = 200;
+ public int f = 200; // PAIL: private to public
public EntitySpectralArrow(World world) {
super(world);

View File

@ -25,4 +25,14 @@ public class CraftSpectralArrow extends CraftArrow implements SpectralArrow {
public EntityType getType() {
return EntityType.SPECTRAL_ARROW;
}
@Override
public int getGlowingTicks() {
return getHandle().f; // PAIL: Rename glowingDuration
}
@Override
public void setGlowingTicks(int duration) {
getHandle().f = duration;
}
}