mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-06 23:34:53 +08:00
[starling] You can now override StarlingAtlasAttachmentLoader#getTexture to provide your own texture for a path
This commit is contained in:
parent
262bc26c64
commit
ea7dbecb98
@ -59,7 +59,7 @@ package spine.starling {
|
||||
}
|
||||
|
||||
public function newRegionAttachment(skin : Skin, name : String, path : String) : RegionAttachment {
|
||||
var texture : Texture = atlas.getTexture(path);
|
||||
var texture : Texture = getTexture(path);
|
||||
if (texture == null)
|
||||
throw new Error("Region not found in Starling atlas: " + path + " (region attachment: " + name + ")");
|
||||
var attachment : RegionAttachment = new RegionAttachment(name);
|
||||
@ -96,7 +96,7 @@ package spine.starling {
|
||||
}
|
||||
|
||||
public function newMeshAttachment(skin : Skin, name : String, path : String) : MeshAttachment {
|
||||
var texture : Texture = atlas.getTexture(path);
|
||||
var texture : Texture = getTexture(path);
|
||||
if (texture == null)
|
||||
throw new Error("Region not found in Starling atlas: " + path + " (mesh attachment: " + name + ")");
|
||||
var rotated : Boolean = atlas.getRotation(path);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user