To change the colour in a script, you will need to get the Sprite Renderer in your code, and then we can easily change it’s color property. If you want to completely change colours, you’ll have to start with a white sprite, otherwise it will just tint. ![]() Now unfortunately if you turn blue and green off, the sprite won’t be all red, just tinted red. You’ll notice also that the colours range from 0 to 255, with 0 being no colour and 255 being full colour. Now if you click on “Color”, you can manually change the sprites transparency in the colour changer by turning alpha down to 0, or tint the sprite by modifying how much red, blue and green is in the image.Ĭonfusingly, if it’s set to all white, the sprite is its normal colour, while all black will make the sprite black. You’re sprite is contained in a component called the Sprite Renderer.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |