Trigger / Beings Casting

Anything.

New Member
Reaction score
69
I'm trying to make a casting system so that when a unit begins casting, it creates an effect, and when it dies / stops / finishes casting, it removes the effect. The effect currently only appears after the unit finishes casting and removes itself in about 1 seconds.

Code:
Fire Spell
    Events
        Unit - A unit Begins casting an ability
    Conditions
        ((Casting unit) is A Hero) Equal to True
        Or - Any (Conditions) are true
            Conditions
                (Ability being cast) Equal to Feral Spirit (Test)
    Actions
        Special Effect - Create a special effect attached to the (hand + left) of (Casting unit) using Abilities\Weapons\FireBallMissile\FireBallMissile.mdl
        Set SpellLeft[(Player number of (Owner of (Casting unit)))] = (Last created special effect)
        Special Effect - Create a special effect attached to the (hand + right) of (Casting unit) using Abilities\Weapons\FireBallMissile\FireBallMissile.mdl
        Set SpellRight[(Player number of (Owner of (Casting unit)))] = (Last created special effect)
        Animation - Play (Casting unit)'s (spell + loop) animation

Code:
Finish Cast
    Events
        Unit - A unit Finishes casting an ability
    Conditions
        ((Casting unit) is A Hero) Equal to True
    Actions
        Animation - Reset (Dying unit)'s animation
        Special Effect - Destroy SpellLeft[(Player number of (Owner of (Casting unit)))]
        Special Effect - Destroy SpellRight[(Player number of (Owner of (Casting unit)))]
 
G

Goauld

Guest
You should use starts the effect of an ability and stops casting an ability as your events. Stops casting includes all possibilities of stopping but finishes casting is only when the unit fully finishes the spell and its spell animation has ended.

Animation - Reset (Dying unit)'s animation
There's no dying unit, what should this refer to? Casting unit? Triggering unit is better than casting unit or dying unit in any trigger that has "some unit does something" as an event.

Channeling a normal spell isn't considered starts casting btw, if you wanted the art to show up during that time it's pretty hard to do.
 

Anything.

New Member
Reaction score
69
Goauld said:
You should use starts the effect of an ability and stops casting an ability as your events. Stops casting includes all possibilities of stopping but finishes casting is only when the unit fully finishes the spell and its spell animation has ended.


There's no dying unit, what should this refer to? Casting unit? Triggering unit is better than casting unit or dying unit in any trigger that has "some unit does something" as an event.

Channeling a normal spell isn't considered starts casting btw, if you wanted the art to show up during that time it's pretty hard to do.
Er, I swore I changed that code while editing. It's correct in my trigger editor though. That last code is a bit messed up, but it doesn't matter because I fixed it.

If casting time doesn't relate to when a unit starts and finishes casting, then what does? When does the unit start casting and when does it finish casting? I'm not trying to make the spell channel, but rather i want it to play channel animation.

When does a unit stop casting?
 
G

Goauld

Guest
You could try "starts channeling an ability" if your spell has a casting time longer than 0.00 seconds. And then remove the effects with "stops casting an ability". It fires when the casting is finished or cancelled. "Finishes casting an ability" actually comes after the unit has casted the spell and it can auto-attack, so although you always get the spell cast but if you order the unit something right when the spell fires it doesn't count as "finishes casting an ability".
 
T

tomcerveja

Guest
a unit "stops casting" (event) when you issue another order for it during the casting time, die, or finishes casting (complete the casting)

if you're trying to make an effect lasts as long as the unit stands still, or until a time limit (as i imagine youre trying to) you gotta use begins casting and stop casting, just like the other guy said. of course that the spell u're using as base must be useless, and have no non-trigger effects, because non-trigger spells only have their effect cast after the casting time is finished... =P
 

Anything.

New Member
Reaction score
69
tomcerveja said:
a unit "stops casting" (event) when you issue another order for it during the casting time, die, or finishes casting (complete the casting)

if you're trying to make an effect lasts as long as the unit stands still, or until a time limit (as i imagine youre trying to) you gotta use begins casting and stop casting, just like the other guy said. of course that the spell u're using as base must be useless, and have no non-trigger effects, because non-trigger spells only have their effect cast after the casting time is finished... =P
Uhm, I'm thinking that my "Finishes Casting" is actually happening before my "Starts Casting". Funny. I think this because my effect goes on the unit now, but doesn't go away. And then, when I recast the spell a couple more times, the effect doesn't stack on top of the previous, like all effects do.

Wouldn't "Begins channeling" only be used for spells like Starfall and Tranquility?

Er, I'm using Feral Spirit with an 8 second casting time for testing purposes.

Shouldn't stop casting be when a unit stops casting through finishing, ending, interruption, death, and etc.?
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • 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
  • 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 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