| 12-13-2003, 05:47 AM | #1 |
well, i want to know if its possible, ive trigger enchanced a spell like so Events -Unit - Flamey beings casting an Ability Condition -Ability being cast Equal to Flame Actions -Special Effect - Create Blah Blah -Unit Group - Pcik Every unit in (units withing 250) of (position of triggering unit)) matching, blah blah balh, -20 health Now when i level the spell up, i want the unit group action of the -20 health bit to change to -30, how do i do that? |
| 12-13-2003, 05:51 AM | #2 |
Dont you need custom text in order to recognise spell levels |
| 12-13-2003, 06:20 AM | #3 |
welll, im not sure, im new to this... |
| 12-13-2003, 06:23 AM | #4 |
It's quite simple. Creat a trigger named "spellname level." This trigger's sole purpose is to determine the level of a specific hero spell. --- Event (generic unit event) A unit learns an ability. --- Conditions (hero skill comparison) Learned hero skill is equal to Human Archmage - Blizzard (this is the default. don't bother changing it at this point.) --- Actions (set variable) Set spellnamelvl to (spellnamelvl + 1.00) Make sure that the variable "spellnamelvl" is Real. Now that that's done, open your Object Manager and go to Abilities. Find your ability and click on it, just so that you'll know which it is after this next step. Go to View and select "Show abilities as raw data." The name of your ability in the left window will change. You will see a four-digit code in front of each ability. Find your custom one and write down that code. Now go to view and select "Show abilities as raw data" again to return back to normal. Now go into the Trigger Manager again. Make sure the trigger you just made is selected and go to Edit, "Convert to custom text." You'll see a prompt; click ok. Now your tidy little trigger has become a complete JASS maelstrom. No worries, however. Glance at the code. Near the top you should see a four-digit code similar to those you saw in the raw data step (it should start with an 'A'). Simply backspace over those four digits and enter the ones you had written down. Tada. Now, every time a hero invests a point into that skill, the value of the spellnamelvl will increase by one. Use this variable in other triggers to determine the effects of your spell. |
| 12-13-2003, 06:48 AM | #5 |
holy ****, u r a bloooddy genius... Wait a sec, im still stunned, if this is right, how excactly am i changing the -20, to -30 when he invests in another point? alright im stumped, this is what ive got Event - Flame Lord begins casting an ability Con - Abilitiy being cast equal to torrents of fire Action - spellnamelvl = spellnamelvl + 1.00 (note ive done the spellnamelevel thing you told me to) Special Effect - yada yada yada Unit Group - Pick every unit and do -200 health. 2nd trigger Unit - Flame Lord beings casting an ability Con - Ability - Torrents Of Fire Action - Set spelllnamelvl = +1 crap. Action - Pick every unit and do -300 health. Wheni level up it still only does 200 damage, im missing something here. ull need to explain it into simpler terms for me im afraid, im pretty young and stupid :D |
| 12-13-2003, 08:35 AM | #6 |
Whoops sorry, accidently went back and clicked reply again... |
| 12-13-2003, 10:55 AM | #7 |
alright ill try to explain it. It takes 2 triggers one to increase the skill level variable and the other to do the action. for the increase in skill level the thing that is really screwing with you is the fact that you have it triggering off of when a unit starts casting a spell, thats wrong. Have the event Hero learns a skill, have a condition for the skill, the action is +1 to the variable. Also make sure that is works, have it say a the skill level in text to make sure you did that right. Then for the casting trigger set it up just like you did before, make an if\then\else statment and move all the stuff that is in the actions under then, create a condition that is spellnamelvl = 1, set else to do nothing. Now you can copy and paste the if\then\else for each level and change it as need be. This does not add to spellnamelvl at all, like how you have it, all it does is check the level of it. |
| 12-13-2003, 05:56 PM | #8 |
Yes. Spellnamelvl is a value that reflects the skill level of a particular spell, and should not be modified outside of that one learning trigger, only referenced. Here are two ways you could do the damage trigger: This one is easier to comprehend, but takes up more space. --- Event (generic unit event) A unit begins casting an ability. --- Conditions (unit comparison) Casting unit is equal to castingunitsname (in your case, Flame Lord. Just use the 'select unit' function here) (ability comparison) Ability being cast is equal to spellname. --- Actions (if/then/else, multiple functions) If/Then/Else. (this will create a miniature condition/action trigger within the trigger, so to say.) ------ If(condition) (real comparison) spellnamelvl = 1 ------ Than (action) (unit group) Select all units within unit group and set life to (life of picked unit - 200) ------ Else(action) Do nothing You can copy and paste this mini-trigger several times, changing the required value of spellnamelvl and the damage amount in each. There is a better way to do it, though. This one takes a bit more experience with the editor and a decent amount of math competency, but is better overall: --- Event (generic unit event) A unit begins casting an ability. --- Conditions (unit comparison) Casting unit is equal to castingunitsname (in your case, Flame Lord. Just use the 'select unit' function here) (ability comparison) Ability being cast is equal to spellname. --- Actions (unit group) Select all units within unit group and set life to (life of picked unit - (100 + (100 x spellnamelvl))) Shwa. With this simple trigger, whenever you cast the spell, all units effected by it will take 100 damage plus 100 additional damage for skill level of that skill. 200 at level 1, 300 at level 2, 400 at level 3, and so on. Now, I have one question for you that could simplify things even further: what exactly is this spell? From the sound of it, Torrents of Fire is an area of effect spell like Flame Strike, except it deals a specific amount of damage in one hit. |
| 12-13-2003, 07:29 PM | #9 |
OR can't you just make a spell, edit it's damage, and put a trigger titled (spell name here) and say: (spell name here) Events: (unit: Specific Unit Event) Flame Lord Aquires a Target (Generic Unit Event) Flame Lord begins casting an ability Conditions (Ability Comparision)Ability being cast is equal to (spell name here) Events: (Special Effect) Create Special Effect attached to the ORIGIN of TARGETED UNIT using (whatever u want) I think that'll work too.. I'm not sure. |
| 12-13-2003, 11:55 PM | #10 |
Torrents Of Fire is a spell based of Battle Roar, thats why i find it hard how to deal out the damage, but after reading all 3 of the replies to my last post, i can see what i have to do now. Basically TFF is when i have a bloodmage that does his spell animation, then the earth trembles around him, and then BOOM! out come heaps of flame strike animations that deal 200 damage in the first lvl. and then i had the problem of finding out how to do 300 damage, and this is where u guys helped me right now. |
| 12-14-2003, 01:43 AM | #11 |
Well there's one problem with using triggers to deal damage. If the trigger kills a unit, the hero doesn't get credit for the kill, ie no gold or (I think) exp. It also doesn't take magical damage reduction and spell immunity into effect. Does each summoned Flame Strike graphic deal damage, or is damage just dealt equally to all nearby enemies? If the later is the case, you could simply create a spell based on Thunder Clap, change it's damage and set it's slow time to zero, give it a casting time, and change the spell art. |
