| 10-26-2004, 05:50 PM | #1 |
For my map im making it so, you buy an item and you get an ability. If you already have the ability, i want it to set to the next level. Sounds simple. I made the item, "Tome of Cricitcal Strike" because its used soon as its bought. Then i set up a trigger but nothing happens =/. I need to know how to set the level of the ability. Heres the trigger Code:
Critical
Events
Unit - A unit Uses an item
Conditions
(Item-type of (Item being manipulated)) Equal to Tome of Critical Strike
Actions
Unit - Add Critical Strike to (Hero manipulating item)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Level of Critical Strike for (Hero manipulating item)) Equal to 1
Then - Actions
Set Critcalstrike[(Level of Critical Strike for (Hero manipulating item))] = Critcalstrike[((Level of Critical Strike for (Hero manipulating item)) + 1)]
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Level of Critical Strike for (Hero manipulating item)) Equal to 2
Then - Actions
Set Critcalstrike[(Level of Critical Strike for (Hero manipulating item))] = Critcalstrike[((Level of Critical Strike for (Hero manipulating item)) + 1)]
Else - Actions
Do nothing |
| 10-26-2004, 05:54 PM | #2 |
i made one of three triggers: Action: A unit aquires an item Condition= Item = Tome of critical strike Actions: set level of ability +1 add ability ability to hero |
| 10-26-2004, 06:57 PM | #3 |
Right ok, what if they reach lvl 3, just wasting money eh ^_^ Also how do u get set the level of ability,make a variable? |
| 10-26-2004, 07:01 PM | #4 |
Im doing this for my map too, took me an hour or so to perfect it but it works great. Im sure there is an easier way to do this with GUI, BUT if u convert this to JASS and use item and ability codes, u can make 60 of these in less than half the time it would take to make it in GUI. The Trigger might not work perfectly for ur purposes and you may need to tweak like 1 condition or w/e but it SHOULD be fine. Code:
Template
Events
Unit - A unit Acquires an item
Conditions
(Level of Banish - [Good] for (Triggering unit)) Not equal to 3
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item being manipulated)) Equal to Banish
(Level of Banish - [Good] for (Hero manipulating item)) Equal to 0
Then - Actions
Unit - Add Banish - [Good] to (Hero manipulating item)
Skip remaining actions
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item being manipulated)) Equal to Banish
(Level of Banish - [Good] for (Hero manipulating item)) Equal to 1
Then - Actions
Unit - Set Level of Banish - [Good] for (Hero manipulating item) to 2
Skip remaining actions
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item being manipulated)) Equal to Banish
(Level of Banish - [Good] for (Hero manipulating item)) Equal to 2
Then - Actions
Unit - Set Level of Banish - [Good] for (Hero manipulating item) to 3
Skip remaining actions
Else - Actions
Do nothing |
| 10-26-2004, 07:13 PM | #5 |
Damn it, cant find the action that sets the level of the ability, thats all. It must be a variable ,cant be ability variable...but it has to be ARG Can u send me the trigger. It would mean a great deal of help to me and prolly a respect point |
| 10-26-2004, 07:18 PM | #6 |
just use the search funtcion when the action box opens up... |
| 10-26-2004, 07:19 PM | #7 |
Hence cant find the function. |
| 10-26-2004, 07:26 PM | #8 |
that's why u use the search box...type in set ability level... |
| 10-26-2004, 07:30 PM | #9 |
Lol ....no ...... its not showing and i dont need sarcastic remarks right now, because this is realy ****ing me off |
| 10-26-2004, 07:39 PM | #10 |
ok, look do u have we 1.17? 1.17 = new patch... if not get on bnet and get update lol. Next, go into trigger editor, make a trigger. Then right click and say "new action" then go to unit - set lvl of ability for unit blah blah if u still cant find it...go to search, it's under the tab that starts off as general...seems simple to me ^_- |
| 10-26-2004, 09:23 PM | #11 |
ah i see...its this WEU doesnt have the function |
