I want my boss to change to white color when he's hit. How?

Hi

I want my boss to change color to white for 0.05 sec when he's hit.
I found red, green, blue but what's the code for white?

Thanks
Dom

Comments

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922

    Make an actor open it up and hit the disclosure triangle under color. This will show you the numbers for any color you make the actor. White is 1,1,1

  • AlphaCentoriAlphaCentori Member Posts: 57
    edited August 2014

    Here is what i have. But changing colors to 1, 1, 1 in change attributes?

    Do i have to create 3x change attributes 1 for each colors?

    http://www40.zippyshare.com/v/74812176/file.html

  • SocksSocks London, UK.Member Posts: 12,822

    @AlphaCentori said:
    Here is what i have.

    Your boss actor will need to be white to start with, you cannot make him white by changing the colour channels.

    You need to make two boss images, one white and one normal (I assume he's normally a coloured image) - then use a rule that says when he is hit change his image to the white version, then using a timer, after 0.05 sec change his image to the normal version.

  • AlphaCentoriAlphaCentori Member Posts: 57

    @Socks said:
    You need to make two boss images, one white and one normal (I assume he's normally a coloured image) - then use a rule that says when he is hit change his image to the white version, then using a timer, after 0.05 sec change his image to the normal version.

    Ok will try this. Thanks a lot!

  • AlphaCentoriAlphaCentori Member Posts: 57

    @Socks said:
    You need to make two boss images, one white and one normal (I assume he's normally a coloured image) - then use a rule that says when he is hit change his image to the white version, then using a timer, after 0.05 sec change his image to the normal version.

    It worked.

    That's what i did here:

    http://www65.zippyshare.com/v/18040438/file.html

  • SocksSocks London, UK.Member Posts: 12,822
    edited August 2014

    Good ! Glad it worked for you.

    You don't really need the first timer, getting rid of unneeded timers and behaviours (and so on) improves a games performance and avoids unnecessarily complex code.

    You can simply take the first change image behaviour out of its timer, it will do exactly the same thing without it.

    Like this . . .

  • AlphaCentoriAlphaCentori Member Posts: 57
    edited August 2014

    @Socks said:

    Great it worked also! Thanks for the tips! :)

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    edited August 2014

    @AlphaCentori said:
    Here is what i have. But changing colors to 1, 1, 1 in change attributes?

    Do i have to create 3x change attributes 1 for each colors?

    http://www40.zippyshare.com/v/74812176/file.html

    Just for others who may read this. Yes you need three change attributes one for each color channel as they are each individual attributes aka variables. To better understand variables and logic see my GS logic video series.

Sign In or Register to comment.