Hello Guest

Author Topic: How does tk2dBaseSprite.color behave?  (Read 4698 times)

ealtorfer

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 6
    • View Profile
How does tk2dBaseSprite.color behave?
« on: June 18, 2013, 06:38:08 pm »
Hey there,

In our game we have a need to "colorize" sprites like this:



Setting tk2dBaseSprite.color definitely does...well, something. Can you explain the intended behavior of this property?

Thanks!

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: How does tk2dBaseSprite.color behave?
« Reply #1 on: June 18, 2013, 06:48:06 pm »
It is the same as the Multiply blend mode in Photoshop.
You can modify the shader to get what you need. Some blend modes aren't doable, and some of them will end up costing a lot of performance.

ealtorfer

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 6
    • View Profile
Re: How does tk2dBaseSprite.color behave?
« Reply #2 on: June 18, 2013, 07:09:13 pm »
Sweet - thank you so much. For other people's reference, this is how my reference image looks when adjusted for the fact that tk2dBaseSprite.color behaves like the Multiply blend mode in photoshop:



Just gotta be kind of careful since multiply is a darken blend mode, but I think this will serve my purposes. Thanks!