add Costume
fun addCostume(name: String, dataFormat: String, assetId: String, rotationCenter: Pair<Double, Double>? = null, bitmapResolution: Int = 1, path: Path? = null): Costume
Adds a costume to the sprite.
Parameters
name
The name of the costume.
data Format
The format of the asset.
asset Id
The MD5 hash of the asset file.
rotation Center
The center of rotation.
bitmap Resolution
The resolution for bitmap images.
path
The local path to the asset file.
fun addCostume(path: Path, name: String, bitmapResolution: Int = 1, rotationCenter: Pair<Double, Double>? = null): Costume
Adds a costume from a local file.
Parameters
path
The path to the costume file.
name
The name for the costume.
bitmap Resolution
The resolution for bitmap images.
rotation Center
The center of rotation.