[SOLVED] How do I change color of sprite X to match that of sprite Y?

0 favourites
  • 4 posts
From the Asset Store
Gather the balls with the same color and earn as much score as you can!
  • Hi!

    So I have this simple setup - two small colorful squares (in the same family - named 'Lenses') and one big white rectangle.

    I want it to be so that when I hover with the mouse over any of the small squares, the big white one will change color to match theirs.

    I tried getting it by using the set color to the colorValue property of the small squares, but this does not work... why?

    And how do I make it work?

    Thanks :-)

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • You should make tetrad and theme the same object and make them white (in the sprite editor window), then change the color on the properties bar (left side).

    Also, doing this saves you having to create multiple objects for each color, if you still want to tell them apart, you can use the UID or create an instance variable.

    On your current version the object.colorValue of theme and tetread are 0,0,0 (It is the color value of the properties bar) mainTXT stays the same.

  • Thanks a lot!

  • My pleasure!

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)