/**
 * Created by rockyl on 2020-01-21.
 */

export function getTexture(uuid) {
	return engine.Texture.from(getAssetByUUID(uuid).uuid);
}

export function getTextureByName(name) {
	return engine.Texture.from(getAssetByName(name).uuid);
}

export function playSound(name) {
	engine.playSound(getAssetByName(name).uuid, {keep: true});
}
export function createSvga(name, anchorName?) {
	let inst = new svga.Svga();
	inst.source = 'asset://' + getAssetByName(name).uuid;
	return inst;
}