mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-03 17:52:28 +01:00
Added the implementation of the concept of an Explosive.
By: sunkid <sunkid@iminurnetz.com>
This commit is contained in:
parent
ab72163bb4
commit
4a33e32be6
2 changed files with 40 additions and 2 deletions
|
@ -7,8 +7,6 @@ import org.bukkit.entity.Fireball;
|
|||
|
||||
/**
|
||||
* A Fireball.
|
||||
*
|
||||
* @author Cogito
|
||||
*/
|
||||
public class CraftFireball extends CraftEntity implements Fireball {
|
||||
public CraftFireball(CraftServer server, EntityFireball entity) {
|
||||
|
@ -19,4 +17,20 @@ public class CraftFireball extends CraftEntity implements Fireball {
|
|||
public String toString() {
|
||||
return "CraftFireball";
|
||||
}
|
||||
|
||||
public float getYield() {
|
||||
return ((EntityFireball) getHandle()).yield;
|
||||
}
|
||||
|
||||
public boolean isIncendiary() {
|
||||
return ((EntityFireball) getHandle()).isIncendiary;
|
||||
}
|
||||
|
||||
public void setIsIncendiary(boolean isIncendiary) {
|
||||
((EntityFireball) getHandle()).isIncendiary = isIncendiary;
|
||||
}
|
||||
|
||||
public void setYield(float yield) {
|
||||
((EntityFireball) getHandle()).yield = yield;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,4 +16,28 @@ public class CraftTNTPrimed extends CraftEntity implements TNTPrimed {
|
|||
return "CraftTNTPrimed";
|
||||
}
|
||||
|
||||
public float getYield() {
|
||||
return ((EntityTNTPrimed) getHandle()).yield;
|
||||
}
|
||||
|
||||
public boolean isIncendiary() {
|
||||
return ((EntityTNTPrimed) getHandle()).isIncendiary;
|
||||
}
|
||||
|
||||
public void setIsIncendiary(boolean isIncendiary) {
|
||||
((EntityTNTPrimed) getHandle()).isIncendiary = isIncendiary;
|
||||
}
|
||||
|
||||
public void setYield(float yield) {
|
||||
((EntityTNTPrimed) getHandle()).yield = yield;
|
||||
}
|
||||
|
||||
public int getFuseTicks() {
|
||||
return ((EntityTNTPrimed) getHandle()).a;
|
||||
}
|
||||
|
||||
public void setFuseTicks(int fuseTicks) {
|
||||
((EntityTNTPrimed) getHandle()).a = fuseTicks;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue