I have several identical buildings. They are capable of having behavior A, behavior B or behavior C, or nothing. They can only have these behaviors and only 1 of them at any given time. (not entirely true, all "active" buildings have one extra buff denoting that they are active, I need this buff for other things)
I want to make an ability that swaps the behavior (or lack thereof) from one building to another as well as swapping the state of the 2nd with that of the 1st.
At first I thought transfer behavior would be good, because I can copy from target to caster, then make another that does the reverse... except the second half would move both buffs....
It almost seems like I need to temporarily make a 3rd bldg, move bldg 1's buff to it, 2's buff to 1, and 3's buff to 2, then delete bldg 3.
If this isn't clear, ask away I'll try to make more sense.
I'm looking for a simple way to swap only certain buffs between 2 units - very preferably using the data editor. Trying not to rely on triggers.
PS- Since there are several buffs it almost seems like I need an "if branch" of effects with separate validators for the different buffs on the target (or possibly for every combo of target-buff and caster-buff and just use a set effect to run all the validators, only the correct one of which will follow through) This seems really inefficient.
Sounds like you want to create a persistent effect on both targets and then determine the transfer behavior targets using the Target - Blah Unit - Effect fields. With the applying the two families of different persistent effects you can use a counter behaviour that the initial effect of the first peristent applies the behaviour to the caster which disables applying it a second time and enables applying the second. The peristents then have a validator for each of the three behaviours so that only the persistent for the appropriate behaviour will be applied and the transfer will remove the persistents in the process.
Rollback Post to RevisionRollBack
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
Are you saying if unit 1 has buff A to give unit 2 a ... temp buff A that adds buff A after a delay? so that I can rip buff B off unit 2 and grant it to the # 1 without also taking buff A back?
Like the Mothership - Vortex (Force) effect or several used in the Left 4 Dead map you can get the point/unit of create persistent and search area effects to be the launch and impact sites of several effects. Having 6 create persistent effects and 3 counter buffs you can apply persistents for each pair of buffs that causes a direct swapping with the validators making sure only the correct persistent is applied at any one time while using the same validators to remove the persistents after the swap has taken place.
Basicly you apply a set to the target and based on what buff it has it then applies a buff specific persistent which then applies a vounter buff to prevent you using the same persistent effect again. You then apply the second persistent effect, as there are now two persistent effects marking the two buffed units to swap they can then swap and when the specific buffs are removed the persistent effects will be destroyed by the validators.
There might be an even simpler alternative depending on how you intend to set up the transfer ability.
I have several identical buildings. They are capable of having behavior A, behavior B or behavior C, or nothing. They can only have these behaviors and only 1 of them at any given time. (not entirely true, all "active" buildings have one extra buff denoting that they are active, I need this buff for other things) I want to make an ability that swaps the behavior (or lack thereof) from one building to another as well as swapping the state of the 2nd with that of the 1st.
At first I thought transfer behavior would be good, because I can copy from target to caster, then make another that does the reverse... except the second half would move both buffs....
It almost seems like I need to temporarily make a 3rd bldg, move bldg 1's buff to it, 2's buff to 1, and 3's buff to 2, then delete bldg 3.
If this isn't clear, ask away I'll try to make more sense. I'm looking for a simple way to swap only certain buffs between 2 units - very preferably using the data editor. Trying not to rely on triggers.
PS- Since there are several buffs it almost seems like I need an "if branch" of effects with separate validators for the different buffs on the target (or possibly for every combo of target-buff and caster-buff and just use a set effect to run all the validators, only the correct one of which will follow through) This seems really inefficient.
So the, "Behavior - Behavior" & "Behavior - Count" don't work?
Sounds like you want to create a persistent effect on both targets and then determine the transfer behavior targets using the Target - Blah Unit - Effect fields. With the applying the two families of different persistent effects you can use a counter behaviour that the initial effect of the first peristent applies the behaviour to the caster which disables applying it a second time and enables applying the second. The peristents then have a validator for each of the three behaviours so that only the persistent for the appropriate behaviour will be applied and the transfer will remove the persistents in the process.
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
@DrSuperEvil: Go
DrSE I'm not sure I exactly follow you here.
Are you saying if unit 1 has buff A to give unit 2 a ... temp buff A that adds buff A after a delay? so that I can rip buff B off unit 2 and grant it to the # 1 without also taking buff A back?
Like the Mothership - Vortex (Force) effect or several used in the Left 4 Dead map you can get the point/unit of create persistent and search area effects to be the launch and impact sites of several effects. Having 6 create persistent effects and 3 counter buffs you can apply persistents for each pair of buffs that causes a direct swapping with the validators making sure only the correct persistent is applied at any one time while using the same validators to remove the persistents after the swap has taken place.
Basicly you apply a set to the target and based on what buff it has it then applies a buff specific persistent which then applies a vounter buff to prevent you using the same persistent effect again. You then apply the second persistent effect, as there are now two persistent effects marking the two buffed units to swap they can then swap and when the specific buffs are removed the persistent effects will be destroyed by the validators.
There might be an even simpler alternative depending on how you intend to set up the transfer ability.
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