Removing some unneeded classes
This commit is contained in:
@@ -1,89 +0,0 @@
|
|||||||
package com.garbagemule.MobArena;
|
|
||||||
|
|
||||||
import java.io.Serializable;
|
|
||||||
import org.bukkit.Location;
|
|
||||||
import org.bukkit.World;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* NOTE: I (garbagemule) DID NOT WRITE THIS CLASS (notice the author below)
|
|
||||||
* @author creadri
|
|
||||||
*/
|
|
||||||
@SuppressWarnings("serial")
|
|
||||||
public class EntityPosition implements Serializable{
|
|
||||||
private double x;
|
|
||||||
private double y;
|
|
||||||
private double z;
|
|
||||||
private String world;
|
|
||||||
private float yaw;
|
|
||||||
private float pitch;
|
|
||||||
|
|
||||||
public EntityPosition(double x, double y, double z, String world, float yaw, float pitch) {
|
|
||||||
this.x = x;
|
|
||||||
this.y = y;
|
|
||||||
this.z = z;
|
|
||||||
this.world = world;
|
|
||||||
this.yaw = yaw;
|
|
||||||
this.pitch = pitch;
|
|
||||||
}
|
|
||||||
|
|
||||||
public EntityPosition(Location location) {
|
|
||||||
this.x = location.getX();
|
|
||||||
this.y = location.getY();
|
|
||||||
this.z = location.getZ();
|
|
||||||
this.world = location.getWorld().getName();
|
|
||||||
this.yaw = location.getYaw();
|
|
||||||
this.pitch = location.getPitch();
|
|
||||||
}
|
|
||||||
|
|
||||||
public Location getLocation(World world) {
|
|
||||||
return new Location(world, x, y, z, yaw, pitch);
|
|
||||||
}
|
|
||||||
|
|
||||||
public float getPitch() {
|
|
||||||
return pitch;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setPitch(float pitch) {
|
|
||||||
this.pitch = pitch;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getWorld() {
|
|
||||||
return world;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setWorld(String world) {
|
|
||||||
this.world = world;
|
|
||||||
}
|
|
||||||
|
|
||||||
public double getX() {
|
|
||||||
return x;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setX(double x) {
|
|
||||||
this.x = x;
|
|
||||||
}
|
|
||||||
|
|
||||||
public double getY() {
|
|
||||||
return y;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setY(double y) {
|
|
||||||
this.y = y;
|
|
||||||
}
|
|
||||||
|
|
||||||
public float getYaw() {
|
|
||||||
return yaw;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setYaw(float yaw) {
|
|
||||||
this.yaw = yaw;
|
|
||||||
}
|
|
||||||
|
|
||||||
public double getZ() {
|
|
||||||
return z;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setZ(double z) {
|
|
||||||
this.z = z;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
package com.garbagemule.MobArena;
|
|
||||||
|
|
||||||
import java.io.Serializable;
|
|
||||||
|
|
||||||
public class MAInventoryItem implements Serializable
|
|
||||||
{
|
|
||||||
private static final long serialVersionUID = 739709220350581510L;
|
|
||||||
private int typeId;
|
|
||||||
private int amount;
|
|
||||||
private short durability;
|
|
||||||
|
|
||||||
public MAInventoryItem(int typeId, int amount, short durability)
|
|
||||||
{
|
|
||||||
this.typeId = typeId;
|
|
||||||
this.amount = amount;
|
|
||||||
this.durability = durability;
|
|
||||||
}
|
|
||||||
|
|
||||||
public int getTypeId() { return typeId; }
|
|
||||||
public int getAmount() { return amount; }
|
|
||||||
public short getDurability() { return durability; }
|
|
||||||
}
|
|
||||||
@@ -1,52 +0,0 @@
|
|||||||
package com.garbagemule.MobArena.waves;
|
|
||||||
|
|
||||||
import java.util.Collection;
|
|
||||||
|
|
||||||
import org.bukkit.Location;
|
|
||||||
|
|
||||||
public class RecurrentWave extends AbstractWave
|
|
||||||
{
|
|
||||||
public RecurrentWave(String name, int wave, int frequency, int priority)
|
|
||||||
{
|
|
||||||
super(name, wave, frequency, priority);
|
|
||||||
}
|
|
||||||
|
|
||||||
public RecurrentWave(String name, int wave, int frequency, int priority, WaveType type, WaveGrowth growth)
|
|
||||||
{
|
|
||||||
super(name, wave, frequency, priority, WaveBranch.RECURRENT, type, growth);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void spawn(int wave, Collection<Location> spawnpoints)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setDefault(boolean def)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean matches(int wave)
|
|
||||||
{
|
|
||||||
if (wave < getWave())
|
|
||||||
return false;
|
|
||||||
|
|
||||||
return (wave - getWave()) % getFrequency() == 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Recurrent waves are sorted by their priorities.
|
|
||||||
* If the priorities are equal, the names are compared. This is to
|
|
||||||
* ALLOW "duplicates" in the RECURRENT WAVES collection.
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
public int compareTo(Wave w)
|
|
||||||
{
|
|
||||||
if (getPriority() < w.getPriority())
|
|
||||||
return -1;
|
|
||||||
else if (getPriority() > w.getPriority())
|
|
||||||
return 1;
|
|
||||||
else return getName().compareTo(w.getName());
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
@@ -1,40 +0,0 @@
|
|||||||
package com.garbagemule.MobArena.waves;
|
|
||||||
|
|
||||||
import java.util.Collection;
|
|
||||||
|
|
||||||
import org.bukkit.Location;
|
|
||||||
|
|
||||||
public class SingleWave extends AbstractWave
|
|
||||||
{
|
|
||||||
public SingleWave(String name, int wave)
|
|
||||||
{
|
|
||||||
super(name, wave, 0, 0);
|
|
||||||
setBranch(WaveBranch.SINGLE);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void spawn(int wave, Collection<Location> spawnpoints)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean matches(int wave)
|
|
||||||
{
|
|
||||||
return getWave() == wave;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Single waves are compared by their wave numbers.
|
|
||||||
* If the wave numbers are equal, the waves are equal. This is to
|
|
||||||
* DISALLOW "duplicates" in the SINGLE WAVES collection.
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
public int compareTo(Wave w)
|
|
||||||
{
|
|
||||||
if (this.getWave() < w.getWave())
|
|
||||||
return -1;
|
|
||||||
else if (this.getWave() > w.getWave())
|
|
||||||
return 1;
|
|
||||||
else return 0;
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user