//right now, constructor makes all four locations with max 5 public Inventory() { loc1 = new InventoryLocation(Game1.power.fire, currentMaxPower); loc2 = new InventoryLocation(Game1.power.ice, currentMaxPower); loc3 = new InventoryLocation(Game1.power.wind, currentMaxPower); loc4 = new InventoryLocation(Game1.power.shock, currentMaxPower); //give you 5 shots for each power loc1.addCharge(5); loc2.addCharge(5); loc3.addCharge(5); loc4.addCharge(5); }
//need a constructor public Player(Vector2 startPosition) { //start in whatever spot is passed in. this.position = startPosition; this.health = 100; this.ourOrigin.X = 10; //these depend on the size of our sprite. this.ourOrigin.Y = 10; //probably end up being the center. this.hatOrigin.X = 10; //depends on where the hat sits on the character this.hatOrigin.Y = 2; //ditto this.staffOrigin.X = 20; //need pix of stuff to know these coordts this.staffOrigin.Y = 10; this.fxEmitPosition.X = 22; //this depends on what our guy looks like, place that powers emit from this.fxEmitPosition.Y = 10; this.playerInventory = new Inventory(); selectedLoc = playerInventory.loc1; inJump = false; state.run = false; state.jump = false; state.left = false; state.right = false; }