Package cs.eng1.piazzapanic.stations
Class IngredientStation
- java.lang.Object
-
- com.badlogic.gdx.scenes.scene2d.Actor
-
- cs.eng1.piazzapanic.stations.Station
-
- cs.eng1.piazzapanic.stations.IngredientStation
-
-
Field Summary
Fields Modifier and Type Field Description protected Ingredient
ingredientDispensed
-
Fields inherited from class cs.eng1.piazzapanic.stations.Station
actionAlignment, chefSubjects, id, inUse, nearbyChef, stationImage, uiController
-
-
Constructor Summary
Constructors Constructor Description IngredientStation(int id, com.badlogic.gdx.graphics.g2d.TextureRegion image, StationUIController uiController, StationActionUI.ActionAlignment alignment, Ingredient ingredient)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
doStationAction(StationAction.ActionType action)
Given an action, the station should attempt to do that action based on the chef that is nearby or what ingredient(s) are currently on the station.void
draw(com.badlogic.gdx.graphics.g2d.Batch batch, float parentAlpha)
java.util.List<StationAction.ActionType>
getActionTypes()
-
Methods inherited from class cs.eng1.piazzapanic.stations.Station
addSubject, deregisterFromAllSubjects, drawDebug, drawFoodTexture, getActionAlignment, getId, getSubjects, removeSubject, reset, setImageRotation, update
-
Methods inherited from class com.badlogic.gdx.scenes.scene2d.Actor
act, addAction, addCaptureListener, addListener, ancestorsVisible, ascendantsVisible, clear, clearActions, clearListeners, clipBegin, clipBegin, clipEnd, debug, drawDebugBounds, fire, firstAscendant, getActions, getCaptureListeners, getColor, getDebug, getHeight, getListeners, getName, getOriginX, getOriginY, getParent, getRight, getRotation, getScaleX, getScaleY, getStage, getTop, getTouchable, getUserObject, getWidth, getX, getX, getY, getY, getZIndex, hasActions, hasKeyboardFocus, hasParent, hasScrollFocus, hit, isAscendantOf, isDescendantOf, isTouchable, isTouchFocusListener, isTouchFocusTarget, isVisible, localToActorCoordinates, localToAscendantCoordinates, localToParentCoordinates, localToScreenCoordinates, localToStageCoordinates, moveBy, notify, parentToLocalCoordinates, positionChanged, remove, removeAction, removeCaptureListener, removeListener, rotateBy, rotationChanged, scaleBy, scaleBy, scaleChanged, screenToLocalCoordinates, setBounds, setColor, setColor, setDebug, setHeight, setName, setOrigin, setOrigin, setOriginX, setOriginY, setParent, setPosition, setPosition, setRotation, setScale, setScale, setScaleX, setScaleY, setSize, setStage, setTouchable, setUserObject, setVisible, setWidth, setX, setX, setY, setY, setZIndex, sizeBy, sizeBy, sizeChanged, stageToLocalCoordinates, toBack, toFront, toString
-
-
-
-
Field Detail
-
ingredientDispensed
protected final Ingredient ingredientDispensed
-
-
Constructor Detail
-
IngredientStation
public IngredientStation(int id, com.badlogic.gdx.graphics.g2d.TextureRegion image, StationUIController uiController, StationActionUI.ActionAlignment alignment, Ingredient ingredient)
-
-
Method Detail
-
getActionTypes
public java.util.List<StationAction.ActionType> getActionTypes()
- Overrides:
getActionTypes
in classStation
- Returns:
- the list of possible actions that this station based on the current state
-
doStationAction
public void doStationAction(StationAction.ActionType action)
Description copied from class:Station
Given an action, the station should attempt to do that action based on the chef that is nearby or what ingredient(s) are currently on the station.- Overrides:
doStationAction
in classStation
- Parameters:
action
- the action that needs to be done by this station if it can.
-
-