Skip to content

Commit 053f862

Browse files
committed
Merge pull request phaserjs#1023 from lucbloom/sprite-textureChange-obsolete
Removed obsolete code in setTexture
2 parents 5384251 + 5328069 commit 053f862

1 file changed

Lines changed: 1 addition & 11 deletions

File tree

src/pixi/display/Sprite.js

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -132,17 +132,7 @@ Object.defineProperty(PIXI.Sprite.prototype, 'height', {
132132
*/
133133
PIXI.Sprite.prototype.setTexture = function(texture)
134134
{
135-
// stop current texture;
136-
if(this.texture.baseTexture !== texture.baseTexture)
137-
{
138-
this.textureChange = true;
139-
this.texture = texture;
140-
}
141-
else
142-
{
143-
this.texture = texture;
144-
}
145-
135+
this.texture = texture;
146136
this.cachedTint = 0xFFFFFF;
147137
};
148138

0 commit comments

Comments
 (0)