Remove Buff after unit is killed not working

ayumilove

Youtube account suspended! youtube.com/ayumilove8
Reaction score
110
thanks tom for the tutorial link and for pointing my mistake ! <3

*reads the tutorial*


[edit]

but, i still dont understand why we need to add in this code:
Code:
Caster has buff Killing Frenzy Equal to True

(caster = the beastman) right?

but i dont see the relation of it checking targeted unit is dead.

Code:
Trigger: ActivateFrenzy
Event - A unit starts the effect of an ability
Condition - Ability being cast Equal to SuperFrenzy 
Action - 
Set Caster = Triggering Unit
[COLOR="Red"]Set CasterPoint = (Position of (Triggering Unit)) [/COLOR]
Create 1 Dummy for Owner of Triggering Unit at [COLOR="Red"]CasterPoint[/COLOR] facing 0.00 degrees.
Unit - Add Curse to Last Created Unit
Unit - Order Last Created unity to Undead Banshee Curse Target Unit of Ability Being cast 
Unit - Add a 1 second Generic expiration timer to Triggering Unit
Create 1 Dummy for Ownver of Triggering Unit at [COLOR="Red"]CasterPoint [/COLOR]facing 0.00 degrees.
Unit - Add Inner Fire to Last Created Unit
Unit - Order Last Created unity to Human Priest - Inner Fire Triggering Unit
Unit - Add a 1 second Generic expiration timer to Triggering Unit
[COLOR="Red"]Custom script:   call RemoveLocation (udg_CasterPoint)[/COLOR]

Set Leak_Group = (Units in (Playable map area) matching (((Matching unit) has buff FrenzyVictim) Equal to True))

Turn on CheckFrenzyVictim
Code:
Trigger: CheckFrenzyVictim
Event - A unit dies
Condition - 
Action -
Unit Group - Pick every units in Leak_Group and do (Actions)
Loop Actions -
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    If - Conditions
      (Picked unit) Equal to (Dying unit)
    Then - Actions
      Unit - Remove FrenzyHero buff from Caster
      Set Caster = No unit
    Else - Actions
Custom script:   call DestroyGroup (udg_Leak_Group)
 
C

CrazyJanitor

Guest
I did your trigger exactly and it still isnt working.... i double checked all the buffs and spells and they were all correct but it still is not working i may have a variable assigned incorrectly though. I have Caster as a unit and i have Leak_Group as a unit group. BTW i only need the inner fire dummy unit because the curse based skill gives his target the buff i need it to have.
 

ayumilove

Youtube account suspended! youtube.com/ayumilove8
Reaction score
110
sorry...

the triggers above are meant as a guide, but not a fully working one
i'm still figuring out how to fix the problem <3
 
C

CrazyJanitor

Guest
np. It worked up to the removing of the buff lol and it seems to be exactly how i would need to set it up. This trigger just has me stumped :( .
 

ayumilove

Youtube account suspended! youtube.com/ayumilove8
Reaction score
110
could you provide some information about your spell?
such as innerfire or curse?

what do you actually want to make?

when caster cast the spell, you want the caster to speed up attack?
and what effect do you want it on the target? always miss attack?
 
C

CrazyJanitor

Guest
Curse and inner fire are just the skills i used to give the necessary buffs to the unit. The inner fire spell gives him a buff that makes it so he is unselectable. The curse gives the buff to the target enemy and it is the spell he actually has no dummy units casts this. What the spell actually does is it makes the beastman who casts the spell attack the target until he dies or the target does. He also gets bonus damage and a movement speed bonus.

The only part i am haveing trouble with is removing the buff that the inner fire based spell gives him after his target dies. This is a problem because he is unselectable by his owner while he has this buff on him. I cannot make the buff expire after a certain amount of time because that could leave him sitting there unselectable or he can become selectable before he kills his target.

The spell does not need to be MUI becuase it is on a AOS map and there will be only one beastmaster on the map at a time so two people cannot cast it at once.
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
> The spell does not need to be MUI


Event:
- A unit starts the effect of an ability
Conditions:
- (Ability being cast) equal to ...
Actions:
- Set CasterUnitVariable = (Casting unit)
- Set TargetUnitVariable = (Target unit of ability being cast)
- Trigger - Turn on <the next trigger here>

Event:
- Timer - every 1.0 seconds
Conditions:
- (TargetUnitVariable has buff <some buff>) equal to false
Actions:
- ... do domething to CasterUnitVariable
- Trigger - Turn off (This trigger)
 
C

CrazyJanitor

Guest
Yes! it works! thanks a million for all the help.:) :) :)

*Edit*

I guess i spoke to soon if i use the trigger u just gave me AceHart it seems i cannot have any other trigger for this spell or else it interupts this one. I have tried useing seperate triggers or adding more to the same one. I have also tried useing a new variable for each new trigger but it all interupts it by removing the buff from the target for some reason and all it does is increase the movement speed of the triggering unit.
 

Sim

Forum Administrator
Staff member
Reaction score
534
2 choices:

1. Augment the cooldown so it lasts as long as the cooldown so it may never be casted twice in a row.

2. Make it MUI (More complicated :p)
 
C

CrazyJanitor

Guest
I am willing to make it MUI if someone shows me how. It cant be cast twice in a row and i dont see why that matters, maybe I didnt get my point across cleary. I cannot have more than one trigger while useing AceHart's trigger for this skill if i do it stops the trigger.
 

Sim

Forum Administrator
Staff member
Reaction score
534
Even if you re-explained, I fear I still don't understand.

What do you mean by "stop the trigger"? The spell is interrupted?
 
C

CrazyJanitor

Guest
For some reason it stops the periodic trigger if have additional triggers and this makes it so the buff is not removed.
 

Sim

Forum Administrator
Staff member
Reaction score
534
if you have what additionnal triggers? I can't read in your mind :rolleyes:

which triggers stop your periodic one.
 
C

CrazyJanitor

Guest
Frenzy attack move
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Killing Frenzy
Actions
Set FrenzyAttackMover = (Triggering unit)
Set FrenzyAttackMoverTarget = (Target unit of ability being cast)
Unit - Order Caster to Attack FrenzyAttackMoverTarget

This trigger makes the periodic trigger that AceHart gave me remove the Killing Frenzy buff on the target or it removes it itself. I have tried it with variables and without.
 

Tom Jones

N/A
Reaction score
437
Could you please add all of the triggers involing your frenzy skill to the above post! It sounds like you got two or more. And could you please make use of the code button when posting triggers. It's the # to the right of the quote button.¨
*Edit*
After reading all the post, and getting a general picture of what you want, how about this:
Code:
Frenzy
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Frenzy
    Actions
        Custom script:   local unit udg_tempcaster
        Custom script:   local unit udg_temptarget
        Set tempcaster = (Triggering unit)
        Set temptarget = (Target unit of ability being cast)
        *All of the stuff you want to happen*
        Wait until (((temptarget is dead) Equal to True) or ((tempcaster is dead) Equal to True)), checking every 1.00 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (temptarget is dead) Equal to True
            Then - Actions
                Unit - Remove Frenzy(caster) buff from tempcaster
            Else - Actions
                Unit - Remove Frenzy(target) buff from temptarget
        Set tempcaster = No unit
        Set temptarget = No unit
So this will wait untill either the target or caster dies with removing the buff. If the caster dies, the targets buff will be removed and vice versa.
 
C

CrazyJanitor

Guest
Thanks Tom Jones. Your trigger worked perfectly!:D :D Also thanks to every1 else who helped me with this trigger. I am wondering what the custom scripts do though.
 

ayumilove

Youtube account suspended! youtube.com/ayumilove8
Reaction score
110
wow tom codes looks short and sweet <3

the custom script is to make it to become MUI, right?
MUI uses local variables, and Tom had used local variables in his code,
so you can cast many times o_O
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Monovertex Monovertex:
    How are you all? :D
    +1
  • 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

      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