Complicated trigger - need help

Xebarsis

New Member
Reaction score
7
I apologize if I'm lacking clarity or explaining this in a confusing way, but here it goes. I'm making a spell called Molotov Cocktail; it's based on Silence. I'm basing it on silence because I want it to show the radius that the spell will be impacting. The simple description is I want it to show a missile coming to the targeted position, then once the missile contacts the position all units within a certain range will be hit by shadow strike.

This gets complicated because I don't want the units to be instantly shadow striked, I want it to happen when the missile lands on the spot. So to demonstrate the missile I created a dummy unit on the caster and on the targeted point. Then I order the first dummy unit to cast shadow strike on the second unit, which then runs another trigger to check for the shadow strike buff. If it detects the unit has the shadow strike buff, the trigger then removes the buff and creates a dummy caster for every unit in range and shadow strikes them.

Here are the problems I am encountering. When the receiving dummy caster is hit by the first shadow strike, the buff doesn't apply because the caster is invulnerable. I'm not sure how to get the buff to display at the time when the missile reaches the point.

Secondly, even if I make the dummy caster vulnerable, it only shadow strikes one unit in range when it should be shadow striking all the units in range. Here are my two triggers:

Code:
Molotov Cocktail
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Molotov Cocktail (Item)
    Actions
        Game - Display to (All players) the text: Moo
        Set ThePoint = (Target point of ability being cast)
        Set TheOtherPoint = (Position of (Triggering unit))
        Unit - Create 1 Dummy Killer for (Owner of (Triggering unit)) at ThePoint facing Default building facing degrees
        Set Drunkard = (Last created unit)
        Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
        Unit - Create 1 Dummy Caster for (Owner of (Triggering unit)) at TheOtherPoint facing Default building facing degrees
        Set Bartender = (Last created unit)
        Unit - Add Molotov Cocktail (Graphic) to (Last created unit)
        Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
        Unit - Order Bartender to Night Elf Warden - Shadow Strike Drunkard
        Custom script:   call RemoveLocation (udg_ThePoint)
        Custom script:   call RemoveLocation (udg_TheOtherPoint)

Code:
MC Receiver
    Events
        Time - Every 0.05 seconds of game time
    Conditions
    Actions
        Set MolotovGroup = (Units in (Entire map) matching (((Matching unit) has buff Molotov Cocktail Starter ) Equal to True))
        Unit Group - Pick every unit in MolotovGroup and do (Actions)
            Loop - Actions
                Game - Display to (All players) the text: SOMEONE SHOULD BE B...
                Unit - Remove Molotov Cocktail Starter  buff from (Picked unit)
                Set TheOtherPoint = (Position of (Picked unit))
                Set MolotovVictims = (Units within 512.00 of TheOtherPoint)
                Unit Group - Pick every unit in MolotovVictims and do (Actions)
                    Loop - Actions
                        Unit - Create 1 Dummy Caster for Neutral Extra at TheOtherPoint facing Default building facing degrees
                        Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
                        Unit - Add Molotov Cocktail  to (Last created unit)
                        Unit - Order (Last created unit) to Night Elf Warden - Shadow Strike (Picked unit)
                        Custom script:   call RemoveLocation (udg_TheOtherPoint)
        Custom script:   call DestroyGroup (udg_MolotovGroup)
        Custom script:   call DestroyGroup (udg_MolotovVictims)

Again, sorry that this is so confusing. Let me know if you have any questions.
 

Xorifelse

I'd love to elaborate about discussions...........
Reaction score
87
Custom script: call RemoveLocation (udg_TheOtherPoint)

Is not placed right, put it outside the loop.
 

Builder Bob

Live free or don't
Reaction score
249
To get around the invulnerable problem, make the dummy for a neutral player that won't get targeted automatically, and give it high hp and hp regen.
 

Xebarsis

New Member
Reaction score
7
Hey, doing what you both said actually made the spell work! :eek:

Excellent, the spell works as intended now. However, I've ran into a third problem. My game is based on kills, but I don't know how to make the game know what player used Molotov Cocktail (Item). I want to make it so that if a player uses Molotov Cocktail (Item), then the dummy caster that is created to shadow strike all units in the MolotovVictims group will be owned by the player that used the item so that the kills are registered properly. Any ideas?
 

Xebarsis

New Member
Reaction score
7
Happy Halloween! (BUMP!)

All I need is help on figuring out how to make the dummy caster that spawns for neutral extra that shadow strikes all enemies to spawn for the player who originally used the item, then I can put this thread to rest.

Code:
                        Unit - Create 1 Dummy Caster for [U][B](Owner of (The-Dude-Who-Casted-Molotov Cocktail (Item)))[/B][/U] at TheOtherPoint facing Default building facing degrees
                        Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
                        Unit - Add Molotov Cocktail  to (Last created unit)
                        Unit - Order (Last created unit) to Night Elf Warden - Shadow Strike (Picked unit)
                        Custom script:   call RemoveLocation (udg_TheOtherPoint)
 

YourFace

<span style="color:#9C9C9C;"><strong>Runner Up - T
Reaction score
91
i dont think your custom script is used correctly and
first
did you give him the spell
is the spell based off of shadow strike
does it cost mana
does the unit tend to attack other units
does the skill have any requirements
and is the range long enough
 

Xebarsis

New Member
Reaction score
7
i dont think your custom script is used correctly and
first
did you give him the spell
is the spell based off of shadow strike
does it cost mana
does the unit tend to attack other units
does the skill have any requirements
and is the range long enough

Eh? The entire spell is working fine. All I need to do is set it so that the dummy caster is given to the player who used Molotov Cocktail (item) instead of neutral extra. Unfortunately I don't know how to do that because the spell is started via a buff and I don't know how to make the game detect what player added the buff onto the unit. If anyone knows how I can accomplish this, please let me know.
 

YourFace

<span style="color:#9C9C9C;"><strong>Runner Up - T
Reaction score
91
use the event
unit-finishes casting ability
 

Malkier

New Member
Reaction score
2
correct me if I'm wrong here but all you're after now is "how do i make dummy units owned by the player".

add this to the molotov cocktail trigger
Set Molotovchucker = (Triggering Unit)

and put this into the MC reciever trigger
Unit - Create 1 Dummy Caster for (Owner of (Molotov Chucker) at TheOtherPoint facing Default building facing degrees

so it should make them whatever player used the item ^_^

EDIT: 'change' the action in the MC reciever trigger to "Unit - Create 1 Dummy Caster for (Owner of (Molotov Chucker) at TheOtherPoint facing Default building facing degrees", not put in another action = /
 

Xebarsis

New Member
Reaction score
7
correct me if I'm wrong here but all you're after now is "how do i make dummy units owned by the player".

add this to the molotov cocktail trigger
Set Molotovchucker = (Triggering Unit)

and put this into the MC reciever trigger
Unit - Create 1 Dummy Caster for (Owner of (Molotov Chucker) at TheOtherPoint facing Default building facing degrees

so it should make them whatever player used the item ^_^

EDIT: 'change' the action in the MC reciever trigger to "Unit - Create 1 Dummy Caster for (Owner of (Molotov Chucker) at TheOtherPoint facing Default building facing degrees", not put in another action = /

Thank you, that's just what I needed. :D
 
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