简体   繁体   中英

Change opacity of certain color of Phaser.Sprite

I have a sprite sheet where black pixels stand for transperency. So, when I load a sprite from this sheet, I don't want those pixels to be shown.

Therefore my question is the following: Is there an easy way to tell Phaser that opacity of a certain color of a sprite should be turned transparent?

If you need to do this just one time, then you could do it with the help of online tools like lunapic.com .

Upload your sprite, select a color you want to make transparent and thats it.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM