Package com.prineside.tdi2.shapes
Class StraightMultiLine
java.lang.Object
com.prineside.tdi2.Shape
com.prineside.tdi2.shapes.StraightMultiLine
- All Implemented Interfaces:
 com.badlogic.gdx.utils.Pool.Poolable
- 
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class com.prineside.tdi2.Shape
Shape.Factory<T extends Shape> - 
Method Summary
Modifier and TypeMethodDescriptionvoidappendNode(float x, float y, float color, boolean updatePath) voiddraw(com.badlogic.gdx.graphics.g2d.Batch batch) com.badlogic.gdx.graphics.g2d.TextureRegionintcom.badlogic.gdx.graphics.ColorgetTint()voidreset()Resets the object for reuse.voidsetNodeColor(int nodeIdx, float color) voidsetNodePosition(int idx, float x, float y) voidsetNodes(float[] nodes) x, y, colorvoidsetNodes(float[] nodes, int nodeCount) voidsetTextureRegion(com.badlogic.gdx.graphics.g2d.TextureRegion main, com.badlogic.gdx.graphics.g2d.TextureRegion edge) voidsetTint(com.badlogic.gdx.graphics.Color color) voidsetTint(com.badlogic.gdx.graphics.Color color, float alpha) То же самое, только color.a будет перезаписанvoidsetWidth(float width) void 
- 
Method Details
- 
setWidth
public void setWidth(float width)  - 
setNodes
public void setNodes(float[] nodes, int nodeCount)  - 
setNodes
public void setNodes(float[] nodes) x, y, color - 
getNodeCount
public int getNodeCount() - 
getMainTexture
public com.badlogic.gdx.graphics.g2d.TextureRegion getMainTexture() - 
setTextureRegion
public void setTextureRegion(com.badlogic.gdx.graphics.g2d.TextureRegion main, com.badlogic.gdx.graphics.g2d.TextureRegion edge)  - 
appendNode
public void appendNode(float x, float y, float color, boolean updatePath) - Parameters:
 updatePath- true, чтобы путь был валидным сразу после добавления. В противном случае нужно вызвать updateAllNodes() после добавления всех нод
 - 
setNodePosition
public void setNodePosition(int idx, float x, float y)  - 
updateAllNodes
public void updateAllNodes() - 
setNodeColor
public void setNodeColor(int nodeIdx, float color)  - 
setTint
public void setTint(com.badlogic.gdx.graphics.Color color)  - 
setTint
public void setTint(com.badlogic.gdx.graphics.Color color, float alpha) То же самое, только color.a будет перезаписан - 
getTint
public com.badlogic.gdx.graphics.Color getTint() - 
draw
public void draw(com.badlogic.gdx.graphics.g2d.Batch batch)  - 
reset
public void reset()Description copied from interface:com.badlogic.gdx.utils.Pool.PoolableResets the object for reuse. Object references should be nulled and fields may be set to default values. 
 -