com.TeamHEC.LocomotionCommotion.Train
Class TrainInfoUI

java.lang.Object
  extended by com.badlogic.gdx.scenes.scene2d.Actor
      extended by com.TeamHEC.LocomotionCommotion.UI_Elements.Sprite
          extended by com.TeamHEC.LocomotionCommotion.Train.TrainInfoUI

public class TrainInfoUI
extends Sprite


Field Summary
 com.badlogic.gdx.utils.Array<com.badlogic.gdx.scenes.scene2d.Actor> actors
           
 java.util.ArrayList<Connection> adjacent
           
static com.badlogic.gdx.scenes.scene2d.ui.Label name
           
 SpriteButton planRoute
           
static com.badlogic.gdx.scenes.scene2d.ui.Label routeRemaining
           
static com.badlogic.gdx.scenes.scene2d.ui.Label speed
           
 com.badlogic.gdx.scenes.scene2d.ui.Label.LabelStyle style
           
 Train train
           
 
Fields inherited from class com.TeamHEC.LocomotionCommotion.UI_Elements.Sprite
started
 
Constructor Summary
TrainInfoUI()
           
 
Method Summary
 com.badlogic.gdx.utils.Array<com.badlogic.gdx.scenes.scene2d.Actor> getActors()
          Gets an arraylist for the actors
 void highlightAdjacent()
          Makes the adjacent MapObjs to the Train clickable to add to route...
 void makeVisible(boolean v)
          Sets if the train info is visible
 void showLabel(Train train)
          Show the info label for a train
 void unhighlightAdjacent()
          Unhighlights the connections adjacent to a train
 
Methods inherited from class com.TeamHEC.LocomotionCommotion.UI_Elements.Sprite
act, draw, getPosition, getTexture, getX, getY, increaseX, increaseY, refreshBounds, setPosition, setTexture, setX, setY
 
Methods inherited from class com.badlogic.gdx.scenes.scene2d.Actor
addAction, addCaptureListener, addListener, clear, clearActions, clearListeners, clipBegin, clipBegin, clipEnd, debug, drawDebug, fire, getActions, getCaptureListeners, getColor, getDebug, getHeight, getListeners, getName, getOriginX, getOriginY, getParent, getRight, getRotation, getScaleX, getScaleY, getStage, getTop, getTouchable, getUserObject, getWidth, getX, getY, getZIndex, hasParent, hit, isAscendantOf, isDescendantOf, isTouchable, isVisible, localToAscendantCoordinates, localToParentCoordinates, localToStageCoordinates, moveBy, notify, parentToLocalCoordinates, remove, removeAction, removeCaptureListener, removeListener, rotateBy, scaleBy, scaleBy, screenToLocalCoordinates, setBounds, setColor, setColor, setDebug, setHeight, setName, setOrigin, setOrigin, setOriginX, setOriginY, setPosition, setRotation, setScale, setScale, setScaleX, setScaleY, setSize, setTouchable, setUserObject, setVisible, setWidth, setZIndex, sizeBy, sizeBy, stageToLocalCoordinates, toBack, toFront, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

name

public static com.badlogic.gdx.scenes.scene2d.ui.Label name

speed

public static com.badlogic.gdx.scenes.scene2d.ui.Label speed

routeRemaining

public static com.badlogic.gdx.scenes.scene2d.ui.Label routeRemaining

style

public com.badlogic.gdx.scenes.scene2d.ui.Label.LabelStyle style

planRoute

public SpriteButton planRoute

actors

public com.badlogic.gdx.utils.Array<com.badlogic.gdx.scenes.scene2d.Actor> actors

train

public Train train

adjacent

public java.util.ArrayList<Connection> adjacent
Constructor Detail

TrainInfoUI

public TrainInfoUI()
Method Detail

highlightAdjacent

public void highlightAdjacent()
Makes the adjacent MapObjs to the Train clickable to add to route...


unhighlightAdjacent

public void unhighlightAdjacent()
Unhighlights the connections adjacent to a train


getActors

public com.badlogic.gdx.utils.Array<com.badlogic.gdx.scenes.scene2d.Actor> getActors()
Gets an arraylist for the actors

Returns:
ArrayList actors

showLabel

public void showLabel(Train train)
Show the info label for a train

Parameters:
train -

makeVisible

public void makeVisible(boolean v)
Sets if the train info is visible

Parameters:
v - true if the train info is to be visible