26 lines
459 B
Java
26 lines
459 B
Java
package cicaprojekt;
|
|
|
|
public class Gate extends Tile
|
|
{
|
|
private boolean open = false;
|
|
|
|
|
|
public void spawnStargate(Stargate stargate, Direction direction) {
|
|
if(this.open) adjacentTile.get(direction).spawnStargate(stargate, direction);
|
|
}
|
|
|
|
public void onEntry() {
|
|
}
|
|
|
|
public void onExit() {
|
|
}
|
|
|
|
public boolean isOpen() {
|
|
return open;
|
|
}
|
|
|
|
public void setOpen(boolean gateState) {
|
|
this.open = gateState;
|
|
}
|
|
}
|