Asdded a build menu to the hud and fixed some color isues with the new ProgressBar class
This commit is contained in:
parent
d1a2aa8b4e
commit
2cf489403d
10 changed files with 593 additions and 1168 deletions
|
|
@ -1,26 +1,19 @@
|
|||
package ei.game.scene.buildings;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedList;
|
||||
import java.util.Queue;
|
||||
|
||||
import ei.engine.math.Vector2f;
|
||||
import ei.engine.math.Vector2i;
|
||||
import ei.engine.math.Vector3f;
|
||||
import ei.engine.scene.Node;
|
||||
import ei.game.algo.AStar;
|
||||
import ei.game.algo.AStarNode;
|
||||
import ei.game.gamestate.InGameState;
|
||||
import ei.game.player.Player;
|
||||
import ei.game.scene.GameEntity;
|
||||
import ei.game.scene.Map;
|
||||
import ei.game.scene.units.Unit;
|
||||
import ei.game.scene.weapons.Weapon;
|
||||
import ei.game.scene.weapons.WeaponHandler;
|
||||
|
||||
public abstract class Building extends GameEntity{
|
||||
private ArrayList<Unit> availableUnits;
|
||||
private Queue<Unit> buildQueue;
|
||||
private int buildTime;
|
||||
private Node unitNode;
|
||||
private Vector2i oldPos;
|
||||
private int size;
|
||||
|
|
@ -29,6 +22,7 @@ public abstract class Building extends GameEntity{
|
|||
public Building(int l, Vector2i pos, Player p, int size) {
|
||||
super(l, p);
|
||||
this.size = size;
|
||||
buildQueue = new LinkedList<Unit>();
|
||||
unitNode = new Node("UnitNode");
|
||||
unitNode.setLocation(Map.getPixelByPos(pos.getX(), pos.getY(), this.size));
|
||||
System.out.println("location: "+unitNode.getLocation());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue