Class ItemCell

java.lang.Object
com.badlogic.gdx.scenes.scene2d.Actor
com.badlogic.gdx.scenes.scene2d.Group
com.prineside.tdi2.ui.actors.ItemCell
All Implemented Interfaces:
com.badlogic.gdx.scenes.scene2d.utils.Cullable

public class ItemCell extends com.badlogic.gdx.scenes.scene2d.Group
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final float
     
    static final float
     
    static final float
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    act(float delta)
    Updates the actor based on time.
    void
    draw(com.badlogic.gdx.graphics.g2d.Batch batch, float parentAlpha)
    Draws the group and its children.
    int
     
     
    boolean
     
    void
     
    void
    setColRow(int colIdx, int rowIdx)
    Заменяет форму фона для ровной таблицы.
    void
     
    void
     
    void
    setCount(int count)
     
    void
    setCovered(boolean covered)
     
    void
    setIconAndCount(com.badlogic.gdx.scenes.scene2d.Actor icon, float iconScale, int count)
     
    void
    setItem(Item item, int count)
     
    void
    setItem(ItemStack itemStack)
     
    void
    setNoRarityBackground(boolean noRarityBackground)
     
    void
     
    void
    setSelected(boolean selected)
     
    void
    shine(boolean withParticles, boolean withOpaqueOverlay)
    Вызывать после setColRow и setItem
    void
    showRays(boolean visible)
     

    Methods inherited from class com.badlogic.gdx.scenes.scene2d.Group

    addActor, addActorAfter, addActorAt, addActorBefore, clear, clear, clearChildren, clearChildren, debugAll, drawDebug, findActor, getChild, getChildren, getCullingArea, hasChildren, hit, isTransform, localToDescendantCoordinates, removeActor, removeActor, removeActorAt, setCullingArea, setDebug, setTransform, swapActor, swapActor, toString

    Methods inherited from class com.badlogic.gdx.scenes.scene2d.Actor

    addAction, addCaptureListener, addListener, ancestorsVisible, ascendantsVisible, clearActions, clearListeners, clipBegin, clipBegin, clipEnd, debug, 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, isAscendantOf, isDescendantOf, isTouchable, isTouchFocusListener, isTouchFocusTarget, isVisible, localToActorCoordinates, localToAscendantCoordinates, localToParentCoordinates, localToScreenCoordinates, localToStageCoordinates, moveBy, notify, parentToLocalCoordinates, remove, removeAction, removeCaptureListener, removeListener, rotateBy, scaleBy, scaleBy, screenToLocalCoordinates, setBounds, setColor, setColor, setDebug, setHeight, setName, setOrigin, setOrigin, setOriginX, setOriginY, setPosition, setPosition, setRotation, setScale, setScale, setScaleX, setScaleY, setSize, setTouchable, setUserObject, setVisible, setWidth, setX, setX, setY, setY, setZIndex, sizeBy, sizeBy, stageToLocalCoordinates, toBack, toFront

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

  • Constructor Details

    • ItemCell

      public ItemCell()
  • Method Details

    • act

      public void act(float delta)
      Description copied from class: com.badlogic.gdx.scenes.scene2d.Actor
      Updates the actor based on time. Typically this is called each frame by Stage.act(float).

      The default implementation calls Action.act(float) on each action and removes actions that are complete.

      Overrides:
      act in class com.badlogic.gdx.scenes.scene2d.Group
      Parameters:
      delta - Time in seconds since the last frame.
    • draw

      public void draw(com.badlogic.gdx.graphics.g2d.Batch batch, float parentAlpha)
      Description copied from class: com.badlogic.gdx.scenes.scene2d.Group
      Draws the group and its children. The default implementation calls Group.applyTransform(Batch, Matrix4) if needed, then Group.drawChildren(Batch, float), then Group.resetTransform(Batch) if needed.
      Overrides:
      draw in class com.badlogic.gdx.scenes.scene2d.Group
      parentAlpha - The parent alpha, to be multiplied with this actor's alpha, allowing the parent's alpha to affect all children.
    • showRays

      public void showRays(boolean visible)
    • setCornerText

      public void setCornerText(CharSequence text)
    • setNotificationBubbleEnabled

      public void setNotificationBubbleEnabled(boolean enabled)
    • setNoRarityBackground

      public void setNoRarityBackground(boolean noRarityBackground)
    • setCompact

      public void setCompact()
    • isSelected

      public boolean isSelected()
    • setSelected

      public void setSelected(boolean selected)
    • setColRow

      public void setColRow(int colIdx, int rowIdx)
      Заменяет форму фона для ровной таблицы. Индексы с 0
    • setCovered

      public void setCovered(boolean covered)
    • reveal

      public void reveal()
    • shine

      public void shine(boolean withParticles, boolean withOpaqueOverlay)
      Вызывать после setColRow и setItem
    • setIconAndCount

      public void setIconAndCount(com.badlogic.gdx.scenes.scene2d.Actor icon, float iconScale, int count)
    • setItem

      public void setItem(ItemStack itemStack)
    • setItem

      public void setItem(Item item, int count)
    • getItem

      public Item getItem()
    • setCount

      public void setCount(int count)
    • getCount

      public int getCount()