HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Detect if a unit has an ability

06-30-2004, 03:12 PM#1
Fladian
Is it possible to detect a unit has a certain ability, as example Critical Strike. Is it possible to start a different trigger if he has (or hasn't) that ability?
If so, could some explain it to me...?

-Fladian
06-30-2004, 08:30 PM#2
johnfn
Why dont you so every time they learn an ability it gets added to an array and then you just check the array later? I cant check up on anything because I'm at camp but this should work pretty well.
06-30-2004, 09:06 PM#3
Fladian
Alright, I admit, it sounds quite nooby of me not to understand arrays :( but I never really had a touch for triggers. Always more for terrain, anyway, I'm calming every part of my body down hoping not to get an other breakdown (I had one before which made me stop modding for who knows how long)

Anyway, it seems my question didn't came out exactly right.
I have a trigger to open up a dialoge when a certain unit is selected, though thanks to game caches an ability of the main hero is transfered to the other level if some choices are made right in the first level (bit confusing to say but very easy of course) Anyway, in the next level if a certain character is selected AND has a certain ability, then the action of the trigger should change, with other words, the character should 'say' something else. To put it the most logical, I take there is just a condition to see if the character has the ability, anyway, like I said I'm a terrainer not someone who is an expert with triggers. This triggers shoots (the event) when a certain unit is selected to cut a long story short, and the action should be different if the character has a certain ability or not.

*sigh* this was a lot easier when I did it with health in the first lv...
Well, thanks for your time (and the negative rep. whoever gave it :< anyway, excuse me, I'm not in the best mood ever right now...)
-Fladian
06-30-2004, 11:00 PM#4
Vexorian
If it is a hero skill you can use critical strike

Or if I am missunderstanding you should use Integer comparrision - level of ability for unit , it will be 0 if the unit doesn't have it