完善渐隐场景转换

This commit is contained in:
yhh
2020-06-22 15:27:58 +08:00
parent 3d9730d956
commit 481112cfc2
15 changed files with 247 additions and 277 deletions

View File

@@ -82,4 +82,9 @@ class SpriteRenderer extends RenderableComponent {
this._bitmap.scaleX = this.entity.transform.scale.x * camera.transform.scale.x;
this._bitmap.scaleY = this.entity.transform.scale.y * camera.transform.scale.y;
}
public onRemovedFromEntity(){
if (this._bitmap)
this.stage.removeChild(this._bitmap);
}
}