• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Edit 1:How creating illusions with passive spells that the UI can display and that can cast a Pspell

Status
Not open for further replies.
Level 5
Joined
Sep 6, 2010
Messages
91
(Edit 1.1: Update 1: Add Usable Defense skill to an illusion. Add: Shadow Meld and Root / Unroot also)

As the title says I found a way to add skills to the illusions (Excuse my English, it is not my source language). I suppose that in the versions of War 3 after 1.29 I think I solve this problem, they can correct me if it does not.

I don't know if Blizzard did this, but for an illusion to have a visible ability in the unit's UI, it must already be possessed from the start in the editor, even the condition is that the ability must also be passive.
Now what is the way to add abilities to an illusion that can be seen in the game's UI, ignoring the condition that the unit must have it from the beginning in the editor. What I found is that when a unit has an automatic launch ability from the editor, it should also be set to the default active ability option. For example, we can use "Quill Spray" (Because I see that almost no one uses XD), we put this ability to a unit like this in the image.

Imagen-Quill-Spray.jpg
This will cause, when generating an illusion on that unit, immediately the illusion will generate the command for auto activation of the ability "Quill Spray" in this case the command is "flamingattack", this can be captured with this event "Unit - A unit Is issued an order with no target ”. And ready within the event we can add the abilities we want, the condition is that the abilities are passive or have bugs such as immolation :p. Well, we must also put conditions on the event that only the illusion should be the one that receives these abilities. Example:

Imagen-Detect-Illusion.jpg


Imagen-Illusion-Spell.jpg

That would be all for the moment, keep in mind that if you put it after this event all abilities will become invisible in the interface.

- Create an illusion with a pseudo ability with a cooldown. (Rally Point will be used for this)

Here I simply expose that the Rally Point skill is a skill that can have an illusion and can be seen in the game interface, it can also be added or removed at any time, its code is ‘ARal’. (It cannot be silenced, it only affects the pause and I think freezing breath, I don't know if another ability does this, but if you want to use it change its level from 0 to 1)
Imagen-Rally-Point.jpg

Using the above of how to add abilities to illusions, we can use an example ability like immolation, since this shows uhmmm the cost of magic and has a rare XD bug that shows it in illusion even though it is not a passive ability. Putting together the “Engineering Upgrade” skill (This skill can be added at any time to an illusion, its ability change effect works on illusions too), with a custom Rally Point (Note: you can have custom Rally Point skills). You can design a passive ability that has artificial Cooldown.

My spell caster will be Rally Point, let's take into account that this ability when any unit possesses it, the Smart command does not work but its command continues to execute, so we will simply have to create an event to command a point and command a target , for these, apply this line of Custom script code: call IssueTargetOrder (GetOrderedUnit (), "move", GetOrderTargetUnit ()). Example:

Imagen-Rally-Point-Smart-Point.jpg


Imagen-Rally-Point-Smart-Target.jpg

(Launch Spell is the Rally Point name I put on the map. XD )

Now to add Engineering Upgrade to normal units you can use Leantrop HeroicUnits, it is explained in this link: HeroicUnit - Engineering Upgrade on non-hero units!
The code I use is one for illusions that is also from Leantrop, link here: CreateUnitWithProperties (and improved HeroicUnit)

To perform the artificial Cooldown, I based on the Drain Pipe map and its mechanics, link here: Custom cooldown interface

"[Thanks to Leantrop and Drain Pipe for their solutions.]"

Note 2: to eliminate the noise that Rally Point makes when aiming, use the data importer, and through this path “Sound \ Interface \ RallyPointPlace1.wav” to replace another non-disturbing sound.

Note 3: If you want the Rally Point flag not to appear, you can change it in the game's interface options. b) Model - Rally Indicator: “Change the route to another model you want”

Here I leave the test map with everything said, and everything changed and functional using Mui.
Imagen-Preview-Pseudo-Spell.jpg

Update 1.1: Add Usable Defense skill to an illusion.
In this case, if you add an Item with the Defense ability (unit ability) to a unit, this ability appears in its UI box, I don't know what error happens, but apparently Warcraft 3 does not completely hide this ability and also because It is inside an Item, it is not affected by the illusion code that prevents a spell from being cast.
Note 4: This also works with the Magic Defense skill.
Nota 5: Shadow Meld and Root / Unroot are also functional in illusions. It can be added in an item to make it usable, although I also create it in a normal editor.
Imagen-Preview-Defense-Spell.jpg
Defend.gif
Hide.gif
Wc3BTNUproot.png
 

Attachments

  • Illusion with Skill Pasive&Cooldown(1).w3x
    130 KB · Views: 59
Last edited:
Level 4
Joined
Jun 19, 2018
Messages
31
Thanks, very nice. The second method sounds easier, however it requires an item slot that also reveals which one is an illusion.
To fix this you need to use this trick: Hidden inventories with little code
1) Drop item from slot 1, save it to hash.
2) Give the item which gives item ability like defence.
3) Remove and save to hash items 2-6
4) Give the item that gives a copy of the inventory ability. I didn't check, but maybe it should give only 1 slot.
5) Return all items saved to hash to summoned unit.
Works like a charm.

P.S. Immolation didn't work for me. It is clickable but doesn't trigger any order.
 
Last edited:
Status
Not open for further replies.
Top