• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Spell] Spell

Status
Not open for further replies.
Level 5
Joined
Jul 15, 2012
Messages
101
Need help. I have created a spell that makes you invisible and creates an illusion that walks, dies and explodes. I need to destroy icon of that illusion because it's a hero and i try it by removing that illusion from game, but i can't fix it.

  • Events
  • Unit - A unit enters (Playable map area)
  • Conditions
  • (Entering unit) Equal to InvisibilityCasterCopy1
  • Actions
  • Unit - Order InvisibilityCasterCopy1 to Move To ((Random point in Arena Region <gen>) offset by (Random real number between 50.00 and 150.00 )towards (Random real number between 50.00 and 150.00) degrees
  • Wait 1.00 seconds
  • Unit Group - Pick every unit in (units within 210.00 of (Position of InvisibilityCasterCopy1))and do (Actions)
  • Loop - Actions
  • Unit - Cause InvisibilityCasterCopy1 to damage (Picked unit), dealing 1.00 damage of attack type Spells and damage type Normal
  • Special Effect - Create a special effect at (position of InvisibilityCasterCopy1)using Abilities\Spells\Human\FlameStrike\FlameStrike1.mdl
  • Unit - Kill InvisibilityCasterCopy1
  • (DONT KNOW WHAT TO DO HERE)
  • Unit - Remove InvisibilityCasterCopy1 from the game
 
Last edited:
Level 5
Joined
Jul 15, 2012
Messages
101
It makes a copy of that unit so i can't hide that unit copy icon with that or if i do i don't see main unit's icon. InvisibilityCasterCopy1 is a variable.
 
Level 5
Joined
Jul 15, 2012
Messages
101
I forgot to mention what i want - i want that unit copy death animation and explosion, and then to remove icon. The bug i call it's that it first dissapears (remove) and then after 0.5 seconds explodes and there is no death animation. I want that copy to die and explode at the same time.
  • Invisibility 1 1
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to Invisibility 1
    • Actions
      • Set InvisibilityCaster1 = (Casting unit)
      • Unit - Create 1 (Unit-type of InvisibilityCaster1) for (Owner of InvisibilityCaster1) at (Position of InvisibilityCaster1) facing (Percentage life of InvisibilityCaster1) degrees
      • Unit - Set mana of InvisibilityCasterCopy1 to 0.00
      • Set InvisibilityCasterCopy1 = (Last created unit)
      • Trigger - Turn on Invisibility 1 2 <gen>
  • Invisibility 1 2
    • Events
      • Unit - A unit enters (Playable map area)
    • Conditions
      • (Entering unit) Equal to InvisibilityCasterCopy1
    • Actions
      • Unit - Order InvisibilityCasterCopy1 to Move To ((Random point in Arena Region <gen>) offset by (Random real number between 50.00 and 150.00) towards (Random real number between 50.00 and 150.00) degrees)
      • Wait 1.00 seconds
      • Unit Group - Pick every unit in (Units within 210.00 of (Position of InvisibilityCasterCopy1)) and do (Actions)
        • Loop - Actions
          • Unit - Cause InvisibilityCasterCopy1 to damage (Picked unit), dealing 1.00 damage of attack type Spells and damage type Normal
          • Special Effect - Create a special effect at (Position of InvisibilityCasterCopy1) using Abilities\Spells\Human\FlameStrike\FlameStrike1.mdl
          • Unit - Kill InvisibilityCasterCopy1
          • Unit - Remove InvisibilityCasterCopy1 from the game
  • (He just goes, dissapears and then explodes after ~0.4s)
  • Invisibility 1 2
    • Events
      • Unit - A unit enters (Playable map area)
    • Conditions
      • (Entering unit) Equal to InvisibilityCasterCopy1
    • Actions
      • Unit - Order InvisibilityCasterCopy1 to Move To ((Random point in Arena Region <gen>) offset by (Random real number between 50.00 and 150.00) towards (Random real number between 50.00 and 150.00) degrees)
      • Wait 1.00 seconds
      • Unit Group - Pick every unit in (Units within 210.00 of (Position of InvisibilityCasterCopy1)) and do (Actions)
        • Loop - Actions
          • Unit - Cause InvisibilityCasterCopy1 to damage (Picked unit), dealing 1.00 damage of attack type Spells and damage type Normal
          • Special Effect - Create a special effect at (Position of InvisibilityCasterCopy1) using Abilities\Spells\Human\FlameStrike\FlameStrike1.mdl
          • Unit - Kill InvisibilityCasterCopy1
  • (Now he goes, dies and explodes (all ok) but his icon is not removed, if i remove and wait few seconds by Unit - Remove InvisibilityCasterCopy1 from the game - nothing happens, icon is still not removed.
 
Level 5
Joined
Jul 15, 2012
Messages
101
When you remove the dying unit, everything about the unit disappears from the map that instant. Not after any death animation finishes.

Do you really need to remove the unit? Or is it because it is an illusion you want to corpse or blood laying around?

I need to remove that icon of illusion. Just that copy dies, and i need to remove that icon because it's a hero, or somehow turn that hero into unit or something like that.

Try kill the unit before the special effect and after the special effect add wait action with the death animation time, then remove the unit.

If i remove it when he's dead, icon is still not removed. I first kill him and do special effect (or after, tried both) and then i use command Wait and then remove - doesn't work (icon not removed). If i don't use Wait command - it works and icon removes but i don't have death animation, he just dissapers before explosion.
 
Status
Not open for further replies.
Top