| 09-25-2004, 11:01 PM | #1 |
I did a search but could not get an answer to my problem... What I have is a base spell for my hero, and it runs through it's own triggers. And now I want to add another spell that will buff this spell up. 15 Level - Projectile Spell (Stun, no radius [Firebolt Base]) 5 Level - Enhancer Auto-Cast Spell (No targets, no duration [Slow Base]) The idea is to allow the hero to cast the projectile spell normally whenever they want. So they can level it up and not the enhancer at all and it will just do normal damage etc. Or if you get the enhancer but not the Projectile, the Enhancer is useless on it's own. Then, if you have the Enhancer[Auto-Cast ON] and the Projectile, then when you cast the projectile it will run through some other triggers. (Checking conditions appropriately) If you have both spells, but [Auto-Cast OFF] then it will work as if there was no enhancer spell. Likewise if the Enhancer spell is in cooldown. So I am looking to do something like this: Unit Casts Projectile Check that Unit has Enhancer -If yes -> Run Enhancer Triggers -If no -> Run Normal Triggers Check that Unit has Enhancer [Auto-Cast ON] -If yes -> Continue Enhancer Triggers -If no-> Revert to Normal Triggers Sadly I am doing this in Gui Triggers (since I have about 10 minutes of practice with JASS and I do not trust myself to even attempt making something like this yet) Also: I am having troubles getting the map to "Set unit movement speed to 0" They can still move afterwards. I could always spawn a unit with a stun type ability and do it that way, but I would like to stick with doing it this way (through triggers). I am sure this is very confusing, anything that you may have questions on please ask me ![]() |
| 09-26-2004, 02:27 AM | #2 |
For the condition, do a trigger that uses the "A unit is issued an order with no target", also make a condition to check the unit-type, or the level of your skill or you will have problems with the normal slow spell.Then make 2 if\then elses, one for the order to activate slow(autocast), use an action to set the ordered unit custom value to 1, then in the other if\then else, use the order to deactivate slow, then set the custom value to 0.By this way, in your spell your trigger, you can use the unit custom value to check if slow is activated or not. |
| 09-26-2004, 03:12 AM | #3 |
That helps... Although I guess a hero learning spells, is also qualified as "Not targetting a unit" and thus, sets the values off... So the spell could be off auto-cast, but it could have custom value of 1, or vice versa.. So that helps :) Now how do I tell the unit to cast my Enhancer spell? The Order Strings in the Object Editor I left alone (although every time I attempt to reference these in the Trigger Editor I have NO luck) So right now they are "Slow, Slowon, Slowoff" and in the trigger editor I am trying: Code:
Unit Create 1 Dummy Target "Order (Triggering Unit) to (Human Sorceress - Slow) (Las Created Unit)" Unit Remove last created unit from the game Still also: How do I immobilize a crowd using Triggers? |
| 09-26-2004, 03:53 AM | #4 |
I Guess what you want to do is casting another spell on the target when the enhancer is on, for that, just use the custom value condition, then create dummy, and order it to cast the spell on the target.If you mean activating the autocast, the "slowon" order is the one, in GUI function, it is Human Sorceress - Activate Slow.For the crowd, use a Unit Group variable or a "Pick every unit" action to pick them, then use the unit- Pause unit, that will make the unit to stay like the time has frozen, or issue the "Stop" order, to make them to stop what they are doing . |
| 09-26-2004, 05:45 AM | #5 |
I am still having problems with: When a hero learns a spell, it counts as "a unit is issued an order with no target" I do not know how to get around this... I have tried "order comparison" conditions.. but I do not know the order for "learn skill" So if you have any ideas that would be great. |
