I am trying to make an ability to add to a command card that simply runs a trigger, and/or edits a variable. sounds easy, but i dont even know if this is possible let alone how to do it or where to start. Please help!
You can create a new damage effect that does 0 damage. Tie that effect to your ability and then make a trigger that checks for damage done by that effect in the event.
I am trying to make an ability to add to a command card that simply runs a trigger, and/or edits a variable. sounds easy, but i dont even know if this is possible let alone how to do it or where to start. Please help!
You need several things to do this.
Button for new abiltity (Defined as a standard button)
Ability for new ability ( Defiined as a standard ability)
Effect for new ability (Defined as an instant, this means it goes of right away with out needing a target)
Trigger to Dectect new ability ( Event to use is - Any unit uses abiltiy(ID of the new ability)
Rollback Post to RevisionRollBack
Skype
KageNinpo = SN
My Libraries
DialogLeaderboard & TeamSort
My Projects
SPACEWAR Tribute
Infinite TD
well what im trying to to is build a system to detect which ability was used and count them. out of something like 50 abilities. currently im running tests with just 3 abilities, and im already starting to cludder up my triggers. the way i currently do it is use a wait for trigger action in a trigger specifically designed to detect a specific ability (i need one of these triggers for each ability, this trigger can not have any events because it has to be called by yet another trigger). then i have to create the triger that im waiting for in the detection triger that simply has a Unit Uses Ability event, and counts up a variable. so thats 2 triggers per action...
i just know there must be a better way to do this, maybe with as few as 3 triggers. If i can get an ability from the data editor to change global variable or something, i could maybe do a while loop to detect the ability use instead of creating two new triggers... thats what i was thinking when i made this post anyway
Why exactly do you want to count thier use of the ability? Cause theres lots of ways to go about doing something like that ..... depending on the overall reason for doing so some ways may be better then others.
i couldn't find a way to make a triger look for any ability. Any unit i found easy in the presets. but the only generic option for hte ability field was triggering ability which didnt work at all for some reason. so i resorted to looking for specific abilities rather then any... how do you make a trigger look for any ability used by any unit?
im not very concerned about counting the number of times abilities were used. simply counting up a variable in the "do stuff" section of ur switch block should do just fine.
OK if it doesnt Allow you to use "Any Abiltiy" Then you should add an event for every abiltiy that you want it to watch for Ill edit the post above to show it
Rollback Post to RevisionRollBack
Skype
KageNinpo = SN
My Libraries
DialogLeaderboard & TeamSort
My Projects
SPACEWAR Tribute
Infinite TD
good idea. thanks. that will gt rid of half the triggers id have to make otherwise. ill still have to make 1 trigger per ability though, because i need to have a trigger randomly selecting triggers from a list and playing them, one per ability. ive already done this just fine though using a variable that is an array of triggers and a random int.
though maybe i could make an array of ability commands and select one at random somehow at the top of the detection trigger to compare to in the switch block... hmm
i just did my idea with the array of custom ability commands, and randomly setting a local action command variable to an action command at the index of the result of a random integer function. that should work well
damn the maintenance, wanted to post that before i had to go to work :P. but yeah thanks for the ideas man, really helped.
I am trying to make an ability to add to a command card that simply runs a trigger, and/or edits a variable. sounds easy, but i dont even know if this is possible let alone how to do it or where to start. Please help!
You can create a new damage effect that does 0 damage. Tie that effect to your ability and then make a trigger that checks for damage done by that effect in the event.
You need several things to do this.
-Any unit uses abiltiy(ID of the new ability)@SouLCarveRR: Go
well what im trying to to is build a system to detect which ability was used and count them. out of something like 50 abilities. currently im running tests with just 3 abilities, and im already starting to cludder up my triggers. the way i currently do it is use a wait for trigger action in a trigger specifically designed to detect a specific ability (i need one of these triggers for each ability, this trigger can not have any events because it has to be called by yet another trigger). then i have to create the triger that im waiting for in the detection triger that simply has a Unit Uses Ability event, and counts up a variable. so thats 2 triggers per action...
i just know there must be a better way to do this, maybe with as few as 3 triggers. If i can get an ability from the data editor to change global variable or something, i could maybe do a while loop to detect the ability use instead of creating two new triggers... thats what i was thinking when i made this post anyway
@Baldey: Go
you could use 1 trigger to track them
Why exactly do you want to count thier use of the ability? Cause theres lots of ways to go about doing something like that ..... depending on the overall reason for doing so some ways may be better then others.
@SouLCarveRR: Go
i couldn't find a way to make a triger look for any ability. Any unit i found easy in the presets. but the only generic option for hte ability field was triggering ability which didnt work at all for some reason. so i resorted to looking for specific abilities rather then any... how do you make a trigger look for any ability used by any unit?
im not very concerned about counting the number of times abilities were used. simply counting up a variable in the "do stuff" section of ur switch block should do just fine.
OK if it doesnt Allow you to use "Any Abiltiy" Then you should add an event for every abiltiy that you want it to watch for Ill edit the post above to show it
@SouLCarveRR: Go
good idea. thanks. that will gt rid of half the triggers id have to make otherwise. ill still have to make 1 trigger per ability though, because i need to have a trigger randomly selecting triggers from a list and playing them, one per ability. ive already done this just fine though using a variable that is an array of triggers and a random int.
@Baldey: Go
though maybe i could make an array of ability commands and select one at random somehow at the top of the detection trigger to compare to in the switch block... hmm
@Baldey: Go
Actually you can make a Function that takes a perameter that does your (thing per ability)
you can then run the function that that randoms and passes the random number to the function that handles the stuff for all the abilities.
@SouLCarveRR: Go
i just did my idea with the array of custom ability commands, and randomly setting a local action command variable to an action command at the index of the result of a random integer function. that should work well
damn the maintenance, wanted to post that before i had to go to work :P. but yeah thanks for the ideas man, really helped.