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
 

Dave312

Censored for your safe viewing
Reaction score
269
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.
 

Siretu

Starcraft 2 Editor Moderator
Reaction score
293
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".
 

MissKerrigan

Active Member
Reaction score
23
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
 

Dave312

Censored for your safe viewing
Reaction score
269
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.
 

Dave312

Censored for your safe viewing
Reaction score
269
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
 

MissKerrigan

Active Member
Reaction score
23
I understand it but nothing happens though, I do set this tint color in the poison/slow tower am I right?
 

Dave312

Censored for your safe viewing
Reaction score
269
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.
  • Ghan Ghan:
    Howdy
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though
  • Ghan Ghan:
    Heard Houston got hit pretty bad by storms last night. Hope all is well with TH.
  • The Helper The Helper:
    Power back on finally - all is good here no damage
    +2
  • V-SNES V-SNES:
    Happy Friday!
    +1

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top