TorqueScript Reference
Public Member Functions | List of all members
CompositeSprite Class Reference

#include <CompositeSprite_ScriptBinding.h>

Inherits SceneObject.

Public Member Functions

Integer addSprite ([a][b][c][d][e][f])
 
void clearSpriteAsset ()
 
void clearSprites ()
 
void deselectSprite ()
 
Boolean getBatchCulling ()
 
Boolean getBatchIsolated ()
 
String getBatchLayout ()
 
String getBatchSortMode ()
 
Float getDefaultSpriteAngle ()
 
String getDefaultSpriteSize ()
 
String getDefaultSpriteStride ()
 
Float getSpriteAlphaTest ()
 
Float getSpriteAngle ()
 
String getSpriteAnimation ()
 
Integer getSpriteAnimationFrame ()
 
Float getSpriteBlendAlpha ()
 
String getSpriteBlendColor (allowColorNames)
 
Boolean getSpriteBlendMode ()
 
Integer getSpriteCount ()
 
String getSpriteDataObject ()
 
Float getSpriteDepth ()
 
String getSpriteDstBlendFactor ()
 
Boolean getSpriteFlipX ()
 
Boolean getSpriteFlipY ()
 
Integer getSpriteId ()
 
String getSpriteImage ()
 
Integer getSpriteImageFrame ()
 
String getSpriteLocalPosition ()
 
String getSpriteLogicalPosition ()
 
String getSpriteName ()
 
String getSpriteNamedImageFrame ()
 
String getSpriteRenderGroup ()
 
String getSpriteSize ()
 
String getSpriteSortPoint ()
 
String getSpriteSrcBlendFactor ()
 
String getSpriteUserData ()
 
Boolean getSpriteVisible ()
 
Boolean isSpriteSelected ()
 
String pickArea (startx/y, endx/y)
 
String pickPoint (x/y)
 
String pickRay (startx/y, endx/y)
 
Boolean removeSprite ()
 
Boolean selectSprite (a b[c][d][e][f])
 
Boolean selectSpriteId (int batchId)
 
Boolean selectSpriteName (name)
 
void setBatchCulling (bool batchCulling)
 
void setBatchIsolated (bool batchIsolated)
 
void setBatchLayout (batchLayoutType)
 
void setBatchSortMode (renderSortMode)
 
void setDefaultSpriteAngle (float angle)
 
void setDefaultSpriteSize (float width, [float height])
 
void setDefaultSpriteStride (float strideX, [float strideY]])
 
void setSpriteAlphaTest (float alpha)
 
void setSpriteAngle (float localAngle)
 
void setSpriteAnimation (animationAssetId)
 
void setSpriteAnimationFrame (int animationFrame)
 
void setSpriteBlendAlpha (float alpha)
 
void setSpriteBlendColor (float red, float green, float blue, [float alpha=1.0])
 
void setSpriteBlendMode (bool blendMode)
 
void setSpriteDataObject (object)
 
void setSpriteDepth (float depth)
 
void setSpriteDstBlendFactor (dstBlend)
 
void setSpriteFlipX (bool flipX)
 
void setSpriteFlipY (bool flipY)
 
void setSpriteImage (imageAssetId, [imageFrame])
 
void setSpriteImageFrame (int imageFrame)
 
void setSpriteLocalPosition (float localX, float localY)
 
void setSpriteName (name)
 
void setSpriteNamedImageFrame (namedFrame)
 
void setSpriteRenderGroup (renderGroup)
 
void setSpriteSize (float width, [float height])
 
void setSpriteSortPoint (float localX, float localY)
 
void setSpriteSrcBlendFactor (srcBlend)
 
void setSpriteUserData (data)
 
void setSpriteVisible (bool visible)
 
- Public Member Functions inherited from SceneObject
void addToScene (Scene scene)
 
void applyAngularImpulse (impulse)
 
void applyForce (worldForce X/Y, [worldPoint X/Y])
 
void applyLinearImpulse (worldImpulse X/Y, [worldPoint X/Y])
 
void applyTorque (torque)
 
void attachGui (guiControl guiObject, SceneWindow window, [sizeControl ?=false], [offset ?=Vector2(0, 0)])
 
void cancelFadeTo ()
 
void cancelGrowTo ()
 
void cancelMoveTo ([autoStop=true])
 
void cancelRotateTo ([autoStop=true])
 
void clearCollisionShapes ()
 
void copyAllCollisionShapes (targetObject[, clearTargetShapes?])
 
Integer copyCollisionShape (int shapeIndex, targetObject)
 
Boolean copyFrom (SceneObject object, [copyDynamicFields?=false])
 
Integer createChainCollisionShape (localPointsX/Y, [adjacentLocalPositionStartX, adjacentLocalPositionStartY], [adjacentLocalPositionEndX, adjacentLocalPositionEndY])
 
Integer createCircleCollisionShape (radius, [localPositionX, localPositionY])
 
Integer createEdgeCollisionShape (localPositionStartX, localPositionStartY, localPositionEndX, localPositionEndY, [adjacentLocalPositionStartX, adjacentLocalPositionStartY], [adjacentLocalPositionEndX, adjacentLocalPositionEndY])
 
Integer createPolygonBoxCollisionShape (width, height, [localCentroidX, localCentroidY], [angle])
 
Integer createPolygonCollisionShape (localPointsX/Y)
 
Boolean deleteCollisionShape (int shapeIndex)
 
void detachAllGuiControls ()
 
void detachGui ()
 
Boolean fadeTo (targetColor red/green/blue/alpha, rate)
 
Boolean fadeToTime (targetColor red/green/blue/alpha, time)
 
String getAABB ()
 
Boolean getActive ()
 
Float getAlphaTest ()
 
Float getAngle ()
 
Float getAngularDamping ()
 
Float getAngularVelocity ()
 
String getArea ()
 
String getAreaMax (...)
 
String getAreaMin ()
 
Boolean getAutoSizing ()
 
Boolean getAwake ()
 
Float getBlendAlpha ()
 
String getBlendColor (allowColorNames)
 
Boolean getBlendMode ()
 
String getBodyType ()
 
Boolean getBullet ()
 
String getChainCollisionShapeAdjacentEnd (int shapeIndex)
 
String getChainCollisionShapeAdjacentStart (int shapeIndex)
 
Boolean getChainCollisionShapeHasAdjacentEnd (int shapeIndex)
 
Boolean getChainCollisionShapeHasAdjacentStart (int shapeIndex)
 
String getChainCollisionShapeLocalPoint (int shapeIndex, int pointIndex)
 
Integer getChainCollisionShapePointCount (int shapeIndex)
 
String getCircleCollisionShapeLocalPosition (int shapeIndex)
 
Float getCircleCollisionShapeRadius (int shapeIndex)
 
Boolean getCollisionCallback ()
 
String getCollisionGroups ()
 
String getCollisionLayers ()
 
String getCollisionMasks (...)
 
Boolean getCollisionOneWay ()
 
Float getCollisionShapeArea (int shapeIndex)
 
Integer getCollisionShapeCount ()
 
Float getCollisionShapeDensity (int shapeIndex)
 
Float getCollisionShapeFriction (int shapeIndex)
 
Boolean getCollisionShapeIsSensor (int shapeIndex)
 
Float getCollisionShapeRestitution (int shapeIndex)
 
String getCollisionShapeType (int shapeIndex)
 
Boolean getCollisionSuppress ()
 
String getContact (contactIndex)
 
Integer getContactCount ()
 
Float getDefaultDensity ()
 
Float getDefaultFriction ()
 
Float getDefaultRestitution ()
 
String getDstBlendFactor ()
 
String getEdgeCollisionShapeAdjacentEnd (int shapeIndex)
 
String getEdgeCollisionShapeAdjacentStart (int shapeIndex)
 
Boolean getEdgeCollisionShapeHasAdjacentEnd (int shapeIndex)
 
Boolean getEdgeCollisionShapeHasAdjacentStart (int shapeIndex)
 
String getEdgeCollisionShapeLocalPositionEnd (int shapeIndex)
 
String getEdgeCollisionShapeLocalPositionStart (int shapeIndex)
 
Boolean getFixedAngle ()
 
Boolean getGatherContacts ()
 
Float getGravityScale ()
 
Float getHeight ()
 
Float getInertia ()
 
Boolean getIsPointInCollisionShape (int shapeIndex, worldPointX/Y)
 
Boolean getIsPointInOOBB (worldPointX/Y)
 
Float getLifetime ()
 
Float getLinearDamping ()
 
String getLinearVelocity ()
 
String getLinearVelocityFromLocalPoint (localPointX/Y)
 
String getLinearVelocityFromWorldPoint (worldPointX/Y)
 
String getLinearVelocityPolar ()
 
Float getLinearVelocityX ()
 
Float getLinearVelocityY ()
 
String getLocalCenter ()
 
String getLocalPoint (float worldPointX/Y)
 
String getLocalVector (float worldVectorX/Y)
 
Float getMass ()
 
Boolean getPickingAllowed ()
 
String getPolygonCollisionShapeLocalPoint (int shapeIndex, int pointIndex)
 
Integer getPolygonCollisionShapePointCount (int shapeIndex)
 
String getPosition ()
 
Float getPositionX ()
 
Float getPositionY ()
 
Float getRenderAngle ()
 
String getRenderGroup ()
 
String getRenderPosition ()
 
Integer getScene ()
 
Integer getSceneGroup ()
 
Integer getSceneLayer ()
 
Float getSceneLayerDepth ()
 
String getSize ()
 
Float getSizeX ()
 
Float getSizeY ()
 
Boolean getSleepingAllowed ()
 
Boolean getSleepingCallback ()
 
String getSortPoint ()
 
Float getSortPointX ()
 
Float getSortPointY ()
 
Integer getSoundatIndex ()
 
Integer getSoundsCount ()
 
String getSrcBlendFactor ()
 
Boolean getUpdateCallback ()
 
Boolean getUseInputEvents ()
 
Boolean getVisible ()
 
Float getWidth ()
 
String getWorldCenter ()
 
String getWorldPoint (float localPointX/Y)
 
String getWorldVector (float localVectorX/Y)
 
Boolean growTo (targetSize width/height, rate rateX/rateY)
 
Boolean growToTime (targetSize width/height, time)
 
Boolean isFadeToComplete ()
 
Boolean isGrowToComplete ()
 
Boolean isMoveToComplete ()
 
Boolean isRotateToComplete ()
 
Boolean moveTo (worldPoint X/Y, speed, [autoStop=true], [snapToTarget=true], [margin=0.1])
 
Integer playSound ()
 
void removeFromScene ()
 
Boolean rotateTo (angle, speed, [autoStop=true], [warpToTarget=true])
 
void safeDelete ()
 
void setActive ([bool status?])
 
void setAlphaTest (float alpha)
 
void setAngle (float angle)
 
void setAngularDamping (float damping)
 
void setAngularVelocity (float velocity)
 
void setArea (float x1, float y1, float x2, float y2)
 
void setAwake ([bool status?])
 
void setBlendAlpha (float alpha)
 
void setBlendColor (float red, float green, float blue, [float alpha=1.0])
 
void setBlendMode (bool blendMode)
 
void setBodyType (bodyType type)
 
void setBullet ([bool status?])
 
void setCollisionAgainst (SceneObject object, [clearMasks?=false])
 
void setCollisionCallback ([bool status?])
 
void setCollisionGroups (groups)
 
void setCollisionLayers (layers)
 
void setCollisionMasks (groupMask, [layerMask])
 
void setCollisionOneWay ([bool status?])
 
void setCollisionShapeDensity (int shapeIndex, float density)
 
void setCollisionShapeFriction (int shapeIndex, float friction)
 
void setCollisionShapeIsSensor (int shapeIndex, bool status)
 
void setCollisionShapeRestitution (int shapeIndex, float restitution)
 
void setCollisionSuppress ([bool status?])
 
void setDebugOff (debugOptions)
 
void setDebugOn (debugOptions)
 
void setDefaultDensity (float density, [bool updateShapes])
 
void setDefaultFriction (float friction, [bool updateShapes])
 
void setDefaultRestitution (float restitution, [bool updateShapes])
 
void setDstBlendFactor (dstBlend)
 
void setEnabled (bool status)
 
void setFixedAngle (bool status?)
 
void setGatherContacts (bool gatherContacts)
 
void setGravityScale (float scale)
 
void setHeight (float height)
 
void setLifetime (float lifetime)
 
void setLinearDamping (float damping)
 
void setLinearVelocity (float velocityX, float velocityY)
 
void setLinearVelocityPolar (float angle, float speed)
 
void setLinearVelocityX (float velocityX)
 
void setLinearVelocityY (float velocityY)
 
void setPickingAllowed (bool pickingAllowed)
 
void setPosition (float x, float y)
 
void setPositionX (float x)
 
void setPositionY (float y)
 
void setRenderGroup (renderGroup)
 
void setSceneGroup (integer group)
 
void setSceneLayer (integer layer)
 
void setSceneLayerDepth (float layerDepth)
 
Boolean setSceneLayerDepthBack ()
 
Boolean setSceneLayerDepthBackward ()
 
Boolean setSceneLayerDepthForward ()
 
Boolean setSceneLayerDepthFront ()
 
void setSize (float width, float height)
 
void setSizeX (float width)
 
void setSizeY (float height)
 
void setSleepingAllowed ([bool status?])
 
void setSleepingCallback ([bool status?])
 
void setSortPoint (float x, float y)
 
void setSortPointX (float x)
 
void setSortPointY (float y)
 
void setSrcBlendFactor (srcBlend)
 
void setUpdateCallback ([bool status?])
 
void setUseInputEvents (bool inputStatus)
 
void setVisible (bool status)
 
void setWidth (float width)
 
void stopSound (S32 index)
 
- Public Member Functions inherited from BehaviorComponent
Boolean addBehavior (BehaviorInstance bi)
 
void clearBehaviors ()
 
Boolean connect (outputBehavior, inputBehavior, outputName, inputName)
 
Boolean disconnect (outputBehavior, inputBehavior, outputName, inputName)
 
Integer getBehavior (string BehaviorTemplateName)
 
Integer getBehaviorByIndex (int index)
 
String getBehaviorConnection (outputBehavior, outputName, connectionIndex)
 
Integer getBehaviorConnectionCount (outputBehavior, outputName)
 
Integer getBehaviorCount ()
 
Boolean raise (outputBehavior, outputName, [deltaTime])
 
Boolean removeBehavior (BehaviorInstance bi, [bool deleteBehavior=true])
 
Boolean reOrder (BehaviorInstance inst, [int desiredIndex=0])
 
- Public Member Functions inherited from DynamicConsoleMethodComponent
String callOnBehaviors (methodName, argi)
 
- Public Member Functions inherited from SimComponent
Boolean addComponents (compObjName, compObjName2,...)
 
Integer getComponent (idx)
 
Integer getComponentCount ()
 
Boolean isEnabled ()
 
Boolean removeComponents (compObjName, compObjName2,...)
 
void setEnabled (enabled)
 
- Public Member Functions inherited from SimObject
void assignFieldsFrom (SimObject)
 
Integer clone ([copyDynamicFields=false]?)
 
void delete ()
 
Integer getId ()
 
void setName (newName)
 
String getName ()
 
String getClassNamespace ()
 
String getSuperClassNamespace ()
 
void setClassNamespace (nameSpace)
 
void setSuperClassNamespace ()
 
Boolean isMethod (string methodName)
 
String call (methodName, [args] *)
 
void dumpClassHierarchy ()
 
void dump ()
 
Boolean isMemberOfClass (string classname)
 
String getClassName ()
 
String getFieldValue (fieldName)
 
Boolean setFieldValue (fieldName, value)
 
Boolean setEditFieldValue (fieldName, value)
 
Integer getDynamicFieldCount ()
 
String getDynamicField (index)
 
Integer getFieldCount ()
 
String getField (int index)
 
void setProgenitorFile (file)
 
String getProgenitorFile ()
 
Integer getType ()
 
String getFieldType (fieldName)
 
void setInternalName (string InternalName)
 
String getInternalName ()
 
Boolean isChildOfGroup (groupID)
 
Integer getGroup ()
 
Boolean startTimer (callbackFunction, float timePeriod, [repeat]?)
 
void stopTimer ()
 
Boolean isTimerActive ()
 
Integer schedule (time, command, [arg] *)
 
void startListening (SimObject)
 
void stopListening (SimObject)
 
void addListener (SimObject)
 
void removeListener (SimObject)
 
void removeAllListeners ()
 
void postEvent (String eventName, String data)
 
Boolean save (fileName, [selectedOnly]?)
 
void addFieldFilter (fieldName)
 
void removeFieldFilter (fieldName)
 

Member Function Documentation

◆ addSprite()

Integer addSprite ( )

Adds a sprite at the specified logical position. You must specify the correct number of arguments for the selected layout mode. The created sprite will be automatically selected.

Parameters
ab c d e f Logical positions #1 & #2 and four additional and optional arguments.
Returns
The batch Id of the added sprite or zero if not successful.

◆ clearSpriteAsset()

void clearSpriteAsset ( )

Clears any image or animation asset from the sprite.

Returns
No return value.

◆ clearSprites()

void clearSprites ( )

Removes all sprites.

Returns
No return value.

◆ deselectSprite()

void deselectSprite ( )

Deselects any selected sprite. This is not required but can be used to stop accidental changes to sprites.

Returns
No return value.

◆ getBatchCulling()

Boolean getBatchCulling ( )

Gets whether the sprites are render culled or not

Returns
Whether the sprites are rendered culled or not.

◆ getBatchIsolated()

Boolean getBatchIsolated ( )

Gets whether the sprites are rendered, isolated from other renderings as one batch or not.

Returns
Whether the sprites are rendered, isolated from other renderings as one batch or not.

◆ getBatchLayout()

String getBatchLayout ( )

Gets the batch layout type.

Returns
The batch layout type.

◆ getBatchSortMode()

String getBatchSortMode ( )

Gets the batch render sort mode.

Returns
The render sort mode.

◆ getDefaultSpriteAngle()

Float getDefaultSpriteAngle ( )

Gets the angle at which sprites are created.

Returns
(float angle) The angle at which sprites are created.

◆ getDefaultSpriteSize()

String getDefaultSpriteSize ( )

Gets the size at which sprites are created.

Returns
(float width/float height) The size at which sprites are created.

◆ getDefaultSpriteStride()

String getDefaultSpriteStride ( )

Gets the stride which scales the position at which sprites are created.

Returns
(float strideX/float strideY) The stride which scales the position at which sprites are created.

◆ getSpriteAlphaTest()

Float getSpriteAlphaTest ( )

Gets the sprite alpha test.

Returns
(S32) A value of 0 to 255 if alpha testing is enabled. <0 represents disabled alpha testing.

◆ getSpriteAngle()

Float getSpriteAngle ( )

Gets the sprite local angle.

Returns
The sprite local angle.

◆ getSpriteAnimation()

String getSpriteAnimation ( )

Gets the sprite animation.

Returns
The sprite animation.

◆ getSpriteAnimationFrame()

Integer getSpriteAnimationFrame ( )

Gets current frame index used in the animation for the selected sprite. IMPORTANT: this is not the image frame number!

Returns
The current numerical animation frame for the selected sprite

◆ getSpriteBlendAlpha()

Float getSpriteBlendAlpha ( )

Gets the sprite color alpha (transparency).

Returns
(float alpha) The alpha value, a range from 0.0 to 1.0. Less than zero if alpha testing is disabled.

◆ getSpriteBlendColor()

String getSpriteBlendColor ( allowColorNames  )

Gets the sprite blend color

Parameters
allowColorNamesWhether to allow stock color names to be returned or not. Optional: Defaults to false.
Returns
(float red / float green / float blue / float alpha) The sprite blend color.

◆ getSpriteBlendMode()

Boolean getSpriteBlendMode ( )

Gets whether sprite blending is on or not.

Returns
(bool blendMode) Whether sprite blending is on or not.

◆ getSpriteCount()

Integer getSpriteCount ( )

Gets a count of sprites in the composite.

Returns
The count of sprites in the composite.

◆ getSpriteDataObject()

String getSpriteDataObject ( )

Gets the sprite data object.

Returns
The sprite data object.

◆ getSpriteDepth()

Float getSpriteDepth ( )

Gets the sprite depth.

Returns
The sprite depth.

◆ getSpriteDstBlendFactor()

String getSpriteDstBlendFactor ( )

Gets the sprite destination blend factor.

Returns
(dstBlend) The sprite destination blend factor.

◆ getSpriteFlipX()

Boolean getSpriteFlipX ( )

Gets whether the sprite is flipped along its local X axis or not.

Returns
Whether the sprite is flipped along its local X axis or not.

◆ getSpriteFlipY()

Boolean getSpriteFlipY ( )

Gets whether the sprite is flipped along its local Y axis or not.

Returns
Whether the sprite is flipped along its local Y axis or not.

◆ getSpriteId()

Integer getSpriteId ( )

Gets the SpriteBatchId of the currently selected sprite.

Returns
The SpriteBatchId

◆ getSpriteImage()

String getSpriteImage ( )

Gets the sprite image.

Returns
The sprite image.

◆ getSpriteImageFrame()

Integer getSpriteImageFrame ( )

Gets the sprite image frame.

Returns
The sprite image frame.

◆ getSpriteLocalPosition()

String getSpriteLocalPosition ( )

Gets the sprite local position.

Returns
The sprite local position.

◆ getSpriteLogicalPosition()

String getSpriteLogicalPosition ( )

Gets the sprite logical position.

Returns
The sprite logical position.

◆ getSpriteName()

String getSpriteName ( )

Gets the sprite name.

Returns
The sprite name.

◆ getSpriteNamedImageFrame()

String getSpriteNamedImageFrame ( )

Gets the sprite named image frame.

Returns
The sprite named image frame.

◆ getSpriteRenderGroup()

String getSpriteRenderGroup ( )

Gets the name of the render group used to sort the sprite during rendering.

Returns
The render group used to sort the object during rendering.

◆ getSpriteSize()

String getSpriteSize ( )

Gets the sprite size.

Returns
(float width/float height) The sprite size.

◆ getSpriteSortPoint()

String getSpriteSortPoint ( )

Gets the sprite local sort point.

Returns
The sprite local sort point.

◆ getSpriteSrcBlendFactor()

String getSpriteSrcBlendFactor ( )

Gets the sprite source blend factor.

Returns
(srcBlend) The sprite source blend factor.

◆ getSpriteUserData()

String getSpriteUserData ( )

Gets the sprite user data.

Returns
The sprite user data.

◆ getSpriteVisible()

Boolean getSpriteVisible ( )

Gets whether the sprite is visible or not.

Returns
Whether the sprite is visible or not.

◆ isSpriteSelected()

Boolean isSpriteSelected ( )

Checks whether a sprite is selected or not.

Returns
Whether a sprite is selected or not.

◆ pickArea()

String pickArea ( startx/  y,
endx/  y 
)

Picks sprites intersecting the specified area with optional group/layer masks.

Parameters
startx/yThe coordinates of the start point as either (\x y\ or (x,y)
endx/yThe coordinates of the end point as either (\x y\ or (x,y)
Returns
Returns list of sprite Ids.

◆ pickPoint()

String pickPoint ( x/  y)

Picks sprites intersecting the specified point with optional group/layer masks.

Parameters
x/yThe coordinate of the point as either (\x y\ or (x,y)
Returns
Returns list of sprite Ids.

◆ pickRay()

String pickRay ( startx/  y,
endx/  y 
)

Picks sprites intersecting the specified ray with optional group/layer masks.

Parameters
startx/yThe coordinates of the start point as either (\x y\ or (x,y)
endx/yThe coordinates of the end point as either (\x y\ or (x,y)
Returns
Returns list of sprite Ids

◆ removeSprite()

Boolean removeSprite ( )

Removes the selected sprite.

Returns
Whether the sprite was removed or not.

◆ selectSprite()

Boolean selectSprite ( b[c][d][e][f])

Selects a sprite at the specified logical position.

Parameters
ab c d e f Logical positions #1 & #2 and four additional and optional arguments.
Returns
Whether the sprite was selected or not.

◆ selectSpriteId()

Boolean selectSpriteId ( int  batchId)

Selects a sprite with the specified batch Id.

Parameters
batchIdThe batch Id of the sprite to select.
Returns
Whether the sprite was selected or not.

◆ selectSpriteName()

Boolean selectSpriteName ( name  )

Selects a sprite with the specified name.

Parameters
nameThe name of the sprite.
Returns
Whether the sprite was selected or not.

◆ setBatchCulling()

void setBatchCulling ( bool  batchCulling)

Sets whether the sprites are culled. For sprites that are off-screen this is considerably faster during render at the expense of memory. For small composites with a few sprites, the overhead is probably not worth it.

Returns
No return value.

◆ setBatchIsolated()

void setBatchIsolated ( bool  batchIsolated)

Sets whether the sprites are rendered, isolated from other renderings as one batch or not. When in batch isolated mode, the sprites can be optionally sorted.

Returns
No return value.

◆ setBatchLayout()

void setBatchLayout ( batchLayoutType  )

Sets the batch layout type. The render sort mode is used when isolated batch mode is on.

Parameters
batchLayoutType'none', 'rect' or 'iso' layout types are valid.
Returns
No return value.

◆ setBatchSortMode()

void setBatchSortMode ( renderSortMode  )

Sets the batch render sort mode. The render sort mode is used when isolated batch mode is on.

Returns
No return value.

◆ setDefaultSpriteAngle()

void setDefaultSpriteAngle ( float  angle)

Sets the angle at which sprites are created.

Parameters
angleThe angle at which sprites are created.
Returns
No return value.

◆ setDefaultSpriteSize()

void setDefaultSpriteSize ( float  width)

Sets the size at which sprites are created.

Parameters
widthThe default width of sprites.
heightThe default height of sprites
Returns
No return value.

◆ setDefaultSpriteStride()

void setDefaultSpriteStride ( float  strideX,
[float strideY] ]   
)

Sets the stride which scales the position at which sprites are created.

Parameters
strideXThe default stride of the local X axis.
strideYThe default stride of the local Y axis.
Returns
No return value.

◆ setSpriteAlphaTest()

void setSpriteAlphaTest ( float  alpha)

Set the sprite alpha test.

Parameters
valueNumeric value of 0.0 to 1.0 to turn on alpha testing. Less than zero to disable alpha testing.
Returns
No return Value.

◆ setSpriteAngle()

void setSpriteAngle ( float  localAngle)

Sets the sprites local angle.

Parameters
localAngleThe sprite local angle.
Returns
No return value.

◆ setSpriteAnimation()

void setSpriteAnimation ( animationAssetId  )

Sets the sprite animation.

Parameters
imageAssetIdThe animation to set the sprite to.
Returns
No return value.

◆ setSpriteAnimationFrame()

void setSpriteAnimationFrame ( int  animationFrame)

Sets the current animation frame for the selected sprite. IMPORTANT: this is not the image frame number used in the animation!

Parameters
frameWhich frame of the animation to display
Returns
No return value.

◆ setSpriteBlendAlpha()

void setSpriteBlendAlpha ( float  alpha)

Sets the sprite color alpha (transparency). The alpha value specifies directly the transparency of the image. A value of 1.0 will not affect the object and a value of 0.0 will make the object completely transparent.

Parameters
alphaThe alpha value.
Returns
No return Value.

◆ setSpriteBlendColor()

void setSpriteBlendColor ( float  red,
float  green,
float  blue 
)

or ( stockColorName ) - Sets the sprite blend color.

Parameters
redThe red value.
greenThe green value.
blueThe blue value.
alphaThe alpha value.
Returns
No return Value.

◆ setSpriteBlendMode()

void setSpriteBlendMode ( bool  blendMode)

Sets whether sprite blending is on or not. @blendMode Whether sprite blending is on or not.

Returns
No return Value.

◆ setSpriteDataObject()

void setSpriteDataObject ( object  )

Set the sprite data object. NOTE: This object will be persisted alongside the composite sprite. To clear the object you can pass an empty string.

Returns
No return Value.

◆ setSpriteDepth()

void setSpriteDepth ( float  depth)

Sets the sprites depth.

Parameters
depthThe sprite depth.
Returns
No return value.

◆ setSpriteDstBlendFactor()

void setSpriteDstBlendFactor ( dstBlend  )

Sets the sprite destination blend factor.

Parameters
dstBlendThe sprite destination blend factor.
Returns
No return Value.

◆ setSpriteFlipX()

void setSpriteFlipX ( bool  flipX)

Sets whether the sprite is flipped along its local X axis or not.

Parameters
flipXWhether the sprite is flipped along its local X axis or not.
Returns
No return value.

◆ setSpriteFlipY()

void setSpriteFlipY ( bool  flipY)

Sets whether the sprite is flipped along its local Y axis or not.

Parameters
flipYWhether the sprite is flipped along its local Y axis or not.
Returns
No return value.

◆ setSpriteImage()

void setSpriteImage ( imageAssetId  )

Sets the sprite image and optional frame.

Parameters
imageAssetIdThe image to set the sprite to.
imageFrameThe image frame of the imageAssetId to set the sprite to.
Returns
No return value.

◆ setSpriteImageFrame()

void setSpriteImageFrame ( int  imageFrame)

Sets the sprite image frame.

Parameters
imageFrameThe image frame to set the sprite to.
Returns
No return value.

◆ setSpriteLocalPosition()

void setSpriteLocalPosition ( float  localX,
float  localY 
)

Sets the sprites local position.

Parameters
localXThe local position X.
localYThe local position Y.
Returns
No return value.

◆ setSpriteName()

void setSpriteName ( name  )

Set the sprite name. This must be unique within this composite sprite instance. To clear the name you can pass an empty string.

Returns
No return Value.

◆ setSpriteNamedImageFrame()

void setSpriteNamedImageFrame ( namedFrame  )

Sets the sprite named image frame.

Parameters
namedFrameThe named image frame to set the sprite to.
Returns
No return value.

◆ setSpriteRenderGroup()

void setSpriteRenderGroup ( renderGroup  )

Sets the name of the render group used to sort the sprite during rendering.

Parameters
renderGroupThe name of the render group to use. Defaults to nothing.
Returns
No return value.

◆ setSpriteSize()

void setSpriteSize ( float  width)

Sets the sprite size.

Parameters
widthThe sprite width.
heightThe sprite height
Returns
No return value.

◆ setSpriteSortPoint()

void setSpriteSortPoint ( float  localX,
float  localY 
)

Sets the sprites sort point.

Parameters
localXThe local sort point X.
localYThe local sort point Y.
Returns
No return value.

◆ setSpriteSrcBlendFactor()

void setSpriteSrcBlendFactor ( srcBlend  )

Sets the sprite source blend factor.

Parameters
srcBlendThe sprite source blend factor.
Returns
No return Value.

◆ setSpriteUserData()

void setSpriteUserData ( data  )

Set the sprite user data field.

Parameters
dataA space separated string containing the data you wish to store.
Returns
No return Value.

◆ setSpriteVisible()

void setSpriteVisible ( bool  visible)

Sets whether the sprite is visible or not.

Parameters
visibleWhether the sprite is visible or not.
Returns
No return value.