set tint color by actor-event

MissKerrigan

Active Member
Reaction score
23
Hi,

I made an actor-event if a creep got poisoned, this creep gets a green color
If a creep got slowed, this creep gets a blue color

My question: if a slowed unit gets poisoned, how do I give this a teal color?

Same with corrosion: when a creep got hit by the corrosive tower, it gets a red color
Together with slow, this must becomes purple and together with poison it must get a yellow color
All this 3 behaviors must given the creep a pink color :)


Think if I know 1 thing I know to do all this right?

Hope anybody understands what I'm trying to do here


MissKerrigan
 
When setting a tint, give them a label (and use the Clear Tint Color action to clear that tint label when removing). What happens then is that tints with different labels are applied over the top of each other. So if your unit is slowed and poisoned, the unit will receive a Blue tint and a Green tint, resulting in an overall teal tint.
 
To clarify. In the data editor, in the Events + field, in the "Set Tint color" message.

You can specify a Label. This is used to distinguish between different actor messages and can be used as a reference. By default, the label will be at "Custom". This allows you to enter any string that will later be used as a reference.

Basically, all you have to do is go to where you do your poison tint and set the label to "PoisonLabel"(it can be anything really). Also set the slow tint label to "SlowLabel" and the corrosive tint label to "CorrosiveLabel".
 
I still don't get it

I try to explain my question more detailed:

Poison: the poison behavior takes 10 seconds and targeted unit must turn into green color
Slow: the slow behavior takes 10 seconds and targeted unit must turn into blue color
Corrision: the corrisive behavior takes 10 seconds and targeted unit must turn into red color

Poison + Slow: targeted unit must turn into teal color
Poison + Corrosion: targeted unit must turn into yellow color
Slow + Corrosion: targeted unit must turn into purple color
Slow + Poison + Corrosion: targeted unit must turn into pink color

I have several questions about this:

1. I know how to change the unit color by trigger or actor-event, I just don't understand the next thing:

a unit get's POISONED and 5 seconds later a SLOW tower fires at it (remember all of the behaviors takes 10 seconds)
so the color of the targeted unit must be green first, after 5 seconds it must turns teal, and the finally 5 seconds it must be blue because the last 5 seconds only the SLOW effect is on it

How do I trigger this?

I made 3 triggers:

event: any player using effect 'poison'
condition: none
action: set unit color to player 'green'

event: any player using effect 'slow'
condition: none
action: set unit color to player 'blue'

event: any player using effect 'corrosion'
condition: none
action: set unit color to player 'red'

This seems to work but not the way I want

I don't understand the part if a unit takes multiple behaviors and switch between these colors

MissKerrigan
 
Just to clarify: When a unit has more than one buff, do you want the unit to have a certain colour or do do you want the units colour to be a combination of the colours for each individual buff the unit has? The second option will be much easier to implement if you don't have a preference.
 
I would be using actor-events. In the other thread I explained how to tint the unit when they have a particular buff. You need to do the exact same thing but when you use the Set Tint Color action, there is a parameter called Label (see attached image) which you should set to a value. So in the end, your actor events should look something like this:

Code:
Behaviour.Poison.On
   SetTintColor 150,255,150 0.000000 OneShot PoisonTint

Behaviour.Poison.Off
   ClearTintColor 0.000000 PoisonTint

Behaviour.Slow.On
   SetTintColor 150,150,255 0.000000 OneShot SlowTint

Behaviour.Slow.Off
   ClearTintColor 0.000000 SlowTint

etc...

The way this works is that tints with different labels don't overwrite each other, but rather are added on top of each other. So if a unit has both poison and slow, the unit will be tinted both green and blue to give a teal colour. Let me know if you get stuck or something doesn't make sense.

TintLabels.png
 
I understand it but nothing happens though, I do set this tint color in the poison/slow tower am I right?
 
You need to add it to the GenericUnitBase actor. All unit actors are based on this actor (or another actor based on this actor), so by adding events to this actor, all units will have these events. The alternative would be to add these events to every unit in your map.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    News portal has been retired. Main page of site goes to Headline News forum now
  • The Helper The Helper:
    I am working on getting access to the old news portal under a different URL for those that would rather use that for news before we get a different news view.
  • Ghan Ghan:
    Easily done
    +1
  • The Helper The Helper:
    https://www.thehelper.net/pages/news/ is a link to the old news portal - i will integrate it into the interface somewhere when i figure it out
  • Ghan Ghan:
    Need to try something
  • Ghan Ghan:
    Hopefully this won't cause problems.
  • Ghan Ghan:
    Hmm
  • Ghan Ghan:
    I have converted the Headline News forum to an Article type forum. It will now show the top 20 threads with more detail of each thread.
  • Ghan Ghan:
    See how we like that.
  • The Helper The Helper:
    I do not see a way to go past the 1st page of posts on the forum though
  • The Helper The Helper:
    It is OK though for the main page to open up on the forum in the view it was before. As long as the portal has its own URL so it can be viewed that way I do want to try it as a regular forum view for a while
  • Ghan Ghan:
    Yeah I'm not sure what the deal is with the pagination.
  • Ghan Ghan:
    It SHOULD be there so I think it might just be an artifact of having an older style.
  • Ghan Ghan:
    I switched it to a "Standard" article forum. This will show the thread list like normal, but the threads themselves will have the first post set up above the rest of the "comments"
  • The Helper The Helper:
    I don't really get that article forum but I think it is because I have never really seen it used on a multi post thread
  • Ghan Ghan:
    RpNation makes more use of it right now as an example: https://www.rpnation.com/news/
  • The Helper The Helper:
  • The Helper The Helper:
    What do you think Tom?
  • tom_mai78101 tom_mai78101:
    I will have to get used to this.
  • tom_mai78101 tom_mai78101:
    The latest news feed looks good
  • The Helper The Helper:
    I would like to see it again like Ghan had it the first time with pagination though - without the pagination that view will not work but with pagination it just might...
  • The Helper The Helper:
    This drink recipe I have had more than a few times back in the day! Mind Eraser https://www.thehelper.net/threads/cocktail-mind-eraser.194720/

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top