Focus Fire

Igor_Z

You can change this now in User CP.
Reaction score
61
I made a spell on my riffleman hero that does exactly the same things that the Winrunner's Focus Fire spell does. I based my Riffle Rage spell on Soulburn in order to put a buff on the target. I based the Riffle Rage (Self Cast) on Unholy Frenzy which the dummy uses on my hero in order to do the buff check...

Here is the description:
The Sharpshooter channels wind throughout his riffle to surge an excess of adrenaline, giving him maximum attack speed when firing on the targeted enemy. Damage is reduced in this state by 50/40/30%.

Triggers:

Trigger:
  • RR Damage Detection
    • Events
      • Time - Elapsed game time is 0.00 seconds
    • Conditions
    • Actions
      • Set RR_Groups[1] = (Units in (Playable map area))
      • Unit Group - Pick every unit in RR_Groups[1] and do (Actions)
        • Loop - Actions
          • Trigger - Add to RR Damage Being Dealt <gen> the event (Unit - (Picked unit) Takes damage)
          • Unit Group - Add (Picked unit) to RR_Groups[2]
      • Custom script: call DestroyGroup(udg_RR_Groups[1])
      • Custom script: call DestroyTrigger(gg_trg_RR_Damage_Detection)


Trigger:
  • RR Damage Detection 2
    • Events
      • Unit - A unit enters (Playable map area)
    • Conditions
      • ((Triggering unit) is in RR_Groups[2]) Equal to False
    • Actions
      • Unit Group - Add (Triggering unit) to RR_Groups[2]
      • Trigger - Add to RR Damage Being Dealt <gen> the event (Unit - (Triggering unit) Takes damage)


Trigger:
  • RR Casting
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Riffle Rage
    • Actions
      • Set RR_Caster = (Triggering unit)
      • Set RR_Target = (Target unit of ability being cast)
      • Set RR_Point = (Position of RR_Target)
      • Unit - Add Spell Book (Riffle Rage) to RR_Caster
      • Unit - Create 1 Riffle Rage Dummy for (Owner of RR_Caster) at RR_Point facing Default building facing degrees
      • Set RR_Dummy = (Last created unit)
      • Unit - Add Riffle Rage (Self Cast) to RR_Dummy
      • Unit - Set level of Riffle Rage (Self Cast) for RR_Dummy to (Level of Riffle Rage for RR_Caster)
      • Unit - Order RR_Dummy to Undead Necromancer - Unholy Frenzy RR_Caster
      • Unit - Add a 1.00 second Generic expiration timer to RR_Dummy
      • Unit - Grant shared vision of RR_Target to (Owner of RR_Caster)
      • Wait 0.03 seconds
      • Unit - Order RR_Caster to Attack RR_Target
      • Trigger - Turn on RR Remove Buff <gen>


Trigger:
  • RR Damage Being Dealt
    • Events
    • Conditions
      • (Level of Riffle Rage for (Damage source)) Greater than 0
      • ((Damage source) has buff Riffle Rage (Caster)) Equal to True
      • ((Triggering unit) belongs to an ally of (Owner of (Damage source))) Equal to False
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Triggering unit) Equal to RR_Target
          • ((Triggering unit) has buff Riffle Rage (Target)) Equal to True
        • Then - Actions
          • Unit - Set life of (Triggering unit) to ((Life of (Triggering unit)) + ((Damage taken) x (0.60 - (0.10 x (Real((Level of Riffle Rage for (Damage source))))))))
        • Else - Actions
          • Unit - Remove Spell Book (Riffle Rage) from RR_Caster
          • Unit - Remove Riffle Rage (Caster) buff from RR_Caster
          • Unit - Remove Riffle Rage (Target) buff from RR_Target
          • Unit - Deny shared vision of RR_Target to (Owner of RR_Caster)
          • Custom script: call RemoveLocation(udg_RR_Point)
          • Trigger - Turn off RR Remove Buff <gen>


Trigger:
  • RR Remove Buff
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (((RR_Caster is dead) Equal to True) or ((RR_Target is dead) Equal to True)) or (((RR_Caster has buff Riffle Rage (Caster)) Equal to False) or ((RR_Target has buff Riffle Rage (Target)) Equal to False))
        • Then - Actions
          • Unit - Remove Spell Book (Riffle Rage) from RR_Caster
          • Unit - Remove Riffle Rage (Caster) buff from RR_Caster
          • Unit - Remove Riffle Rage (Target) buff from RR_Target
          • Unit - Deny shared vision of RR_Target to (Owner of RR_Caster)
          • Custom script: call RemoveLocation(udg_RR_Point)
          • Trigger - Turn off (This trigger)
        • Else - Actions


The spell works like it is suppose to but I am concerned... Will it work all the time I cast it because that "Wait" action gives me nightmares. So the real question here is:
"Is there a more efficient way to do this in GUI"...

P.S: I don't like it in MUI
Thank you for your time
 

Kling[o]

New Member
Reaction score
7
Why you don't like MUI? you could make a timer of 0.03 second... then you make a trigger that will run when it expire
 

Igor_Z

You can change this now in User CP.
Reaction score
61
So will something go wrong if I leave the wait in that trigger?
 

tommerbob

Minecraft. :D
Reaction score
110
Why don't you just set the target unit to a variable, and then check whenever the caster deals damage or attacks, and if his target is not the variable, remove the buff from the caster? Seems like this should be really easy.

And yes, waits are buggy. Especially with smalls ones like "wait 0.03 seconds". If I understand correctly, anything under about 1 second will be not be totally accurate. Don't use waits if you can afford it.
 

Igor_Z

You can change this now in User CP.
Reaction score
61
Thank you both of you for the replies. I fixed it with a timer
 

Dyslexia://

New Member
Reaction score
13
2dkioia3.gif


...
Or you can base the ability off of Berserk to add the atk spd [this ability is given to the hero], then...
you can make a Roar with negative atk dmg values and just make a dummy unit cast it around your hero/unit/whatever, then just force atk that one unit...
unless you want to make it so that it only gets the atk spd boost when it targets that one unit AND its able to target other units, but thats still much more easier to use and modify than triggering the damage dealt
 

Igor_Z

You can change this now in User CP.
Reaction score
61
The spell is good as it is. There is always room for improvement, but often the triggers are the ones that need modification... I think I thought of a good idea on how the spell should work. Just that order action gave me some problems.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • 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 The Helper:
    New recipe is another summer dessert Berry and Peach Cheesecake - https://www.thehelper.net/threads/recipe-berry-and-peach-cheesecake.194169/
  • The Helper The Helper:
    I think we need to add something to the bottom of the front page that shows the Headline News forum that has a link to go to the News Forum Index so people can see there is more news. Do you guys see what I am saying, lets say you read all the articles on the front page and you get to the end and it just ends, no kind of link for MOAR!
  • The Helper The Helper:
    Happy Wednesday!
    +1
  • 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