blub
This commit is contained in:
parent
fb77d13eb5
commit
56e19e8039
30 changed files with 485 additions and 37 deletions
|
|
@ -16,16 +16,38 @@
|
|||
*/
|
||||
package de.welterde.em.w;
|
||||
|
||||
import de.welterde.em.EntityBase;
|
||||
import de.welterde.em.EntityRef;
|
||||
import de.welterde.em.EntityStorage;
|
||||
import java.util.EnumSet;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author welterde
|
||||
*/
|
||||
public class Outpost {
|
||||
public class Outpost extends EntityBase {
|
||||
protected final EnumSet<OutpostFlags> flags;
|
||||
protected final OutpostLocationType locationType;
|
||||
protected EntityRef<City> city;
|
||||
|
||||
public Outpost() {
|
||||
public Outpost(EntityStorage ctx, int id, OutpostLocationType locationType) {
|
||||
super(ctx, id);
|
||||
this.flags = EnumSet.noneOf(OutpostFlags.class);
|
||||
this.locationType = locationType;
|
||||
}
|
||||
|
||||
public EnumSet<OutpostFlags> getFlags() {
|
||||
return flags.clone();
|
||||
}
|
||||
|
||||
public OutpostLocationType getLocationType() {
|
||||
return locationType;
|
||||
}
|
||||
|
||||
public City getCity() {
|
||||
if(this.city != null)
|
||||
return this.city.get();
|
||||
else
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue