Hey there, I have been attempting to decide what the best way to do this would be, via behavior search area, or targeted auto cast. The main problem I keep on running into is the issue that I want The unit giving energy to loose more energy when 3 or 4 units are getting energy from it. I really would prefer to do this in the data, I try to avoid really fast periodic triggers when I can.
So here is basically what I want, A unit comes in range of the building, the building gives it's energy periodically until the unit's energy is full.
If there are More units, the building will loose more energy at once because it is giving away allot of energy to those units.
I have looked at search areas, but a simple search area does not (to my knowledge) have the ability to sense how many units are within it, and scale the cost to cast the energy regen ability properly.
I have also been having the issue that Behaviors only allow for one periodic effect within them, because I wanted the periodic behavior to start loosing energy on the casting building as the target unit was gaining energy. I attempted to get by this by creating a buff behavior with a initial effect and a final effect then made an effect that applied that behavior, and the made another behavior that took the apply behavior effect and casted it periodically (did not work :( )
So as of now I am a tad bit stumped, I was curious if anyone has ever made an ability like this before, or if someone knows how this might be done.
I don't see how you should be having any issues at all. Just have a buff with a periodic search that applies a set that takes and gives energy. Even without this, yes you can scale costs but it a bit more work; you'd need a switch and a validator which can indead tell how many units there are.
Use an aura like buff system on the building that applies buffs to the targets. Have the buffs use a periodic set effect that uses Modify Unit effects or Create Healer effects. Apply a third buff back to the caster that has a stack cap based on the number of casters (might not work) or have several modify unit effects validated by Enumerate Area validators. If the building has a cap on the number of units it can serve you can add a Unit Compare Behavior Count validator to the enumerate area one.
Rollback Post to RevisionRollBack
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
I will see what I can do with that, the concept seemed so simple, but now that I am attempting to execute it my mind is fried
Edit: I HAD AN IDEA, I am going to attempt to give the units a behavior that gives a stackable debuff to the nexus, while the nexus simply has a buff area, yeah ill do that! I will post if I get it to work.
Edit: What I did works like a charm, the idea dawned on me when I was reminded buffs could stack in reading DrSuperEvil's post. Now I just need to add 1 or 2 validators and I will be done thanks :D .
Hey there, I have been attempting to decide what the best way to do this would be, via behavior search area, or targeted auto cast. The main problem I keep on running into is the issue that I want The unit giving energy to loose more energy when 3 or 4 units are getting energy from it. I really would prefer to do this in the data, I try to avoid really fast periodic triggers when I can.
So here is basically what I want, A unit comes in range of the building, the building gives it's energy periodically until the unit's energy is full. If there are More units, the building will loose more energy at once because it is giving away allot of energy to those units.
I have looked at search areas, but a simple search area does not (to my knowledge) have the ability to sense how many units are within it, and scale the cost to cast the energy regen ability properly.
I have also been having the issue that Behaviors only allow for one periodic effect within them, because I wanted the periodic behavior to start loosing energy on the casting building as the target unit was gaining energy. I attempted to get by this by creating a buff behavior with a initial effect and a final effect then made an effect that applied that behavior, and the made another behavior that took the apply behavior effect and casted it periodically (did not work :( )
So as of now I am a tad bit stumped, I was curious if anyone has ever made an ability like this before, or if someone knows how this might be done.
I don't see how you should be having any issues at all. Just have a buff with a periodic search that applies a set that takes and gives energy. Even without this, yes you can scale costs but it a bit more work; you'd need a switch and a validator which can indead tell how many units there are.
Use an aura like buff system on the building that applies buffs to the targets. Have the buffs use a periodic set effect that uses Modify Unit effects or Create Healer effects. Apply a third buff back to the caster that has a stack cap based on the number of casters (might not work) or have several modify unit effects validated by Enumerate Area validators. If the building has a cap on the number of units it can serve you can add a Unit Compare Behavior Count validator to the enumerate area one.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
I will see what I can do with that, the concept seemed so simple, but now that I am attempting to execute it my mind is fried
Edit: I HAD AN IDEA, I am going to attempt to give the units a behavior that gives a stackable debuff to the nexus, while the nexus simply has a buff area, yeah ill do that! I will post if I get it to work.
Edit: What I did works like a charm, the idea dawned on me when I was reminded buffs could stack in reading DrSuperEvil's post. Now I just need to add 1 or 2 validators and I will be done thanks :D .