I have a problem with the map I'm making, based on the Illidan character of the Warcraft universe.
I gave the unit ("Hero" is the name) three custom attributes: Strength, Stamina and Intellect.
I created an ability, through triggers, that morphs the unit by changing its model (to simulate the Metamorphosis ability) and wanted to give to this new form two characteristics:
1 - Increase attack speed by 100%
2 - Increase Strength by 30%
I managed to change the Attack speed by modifying the attackspeedmultiplier value (through a Catalog function), however I can't find a way to find the value of the custom attribute "Strength" in order to increase it by 30%...
I've thought about it and actually there's no such field value as "quantity" for custom attributes, so I really don't know what to do in order to change it.
(Strength is a custom attribute and I made it so that you obtain 1 point for each level of the Hero, through veterancy).
Your first problem is that you did this through triggers. Anything to do with unit properties (except death) should really be handled using the data editor. All of these things can be done using the data editor. You can look off of the larva for guides on how to morph (or a tutorial from my signature link). All stat/attribute changes can be done through behaviors or effects. There are tutorials for those as well.
If you're really stuck on using triggers, there is a "set unit custom value" trigger action, or the "add behavior" action you could make a behavior which adds those stats. One of those might fulfill your needs.
You can modify attributes simply by adding stacks of the attribute behaviour to the unit. Like wise the stack count of the attribute behaviour is the quantity of that attribute.
I would recommend avoiding attributes. Professional design analysis has shown that attributes are nothing more than UI clutter and complicate mechanics. Practically everything done by an attribute can be applied directly to the unit in a way that is both simpler and more clear. For example instead of raising strength by 30% it could add 30% more health.
Avoid excessive use of catalog natives. At one stage they leaked quite badly (not sure if they patched that yet or not).
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hello everyone,
I have a problem with the map I'm making, based on the Illidan character of the Warcraft universe.
I gave the unit ("Hero" is the name) three custom attributes: Strength, Stamina and Intellect.
I created an ability, through triggers, that morphs the unit by changing its model (to simulate the Metamorphosis ability) and wanted to give to this new form two characteristics:
1 - Increase attack speed by 100%
2 - Increase Strength by 30%
I managed to change the Attack speed by modifying the attackspeedmultiplier value (through a Catalog function), however I can't find a way to find the value of the custom attribute "Strength" in order to increase it by 30%...
I've thought about it and actually there's no such field value as "quantity" for custom attributes, so I really don't know what to do in order to change it.
(Strength is a custom attribute and I made it so that you obtain 1 point for each level of the Hero, through veterancy).
Can someone help me?
Thanks
Your first problem is that you did this through triggers. Anything to do with unit properties (except death) should really be handled using the data editor. All of these things can be done using the data editor. You can look off of the larva for guides on how to morph (or a tutorial from my signature link). All stat/attribute changes can be done through behaviors or effects. There are tutorials for those as well.
If you're really stuck on using triggers, there is a "set unit custom value" trigger action, or the "add behavior" action you could make a behavior which adds those stats. One of those might fulfill your needs.
New to the Editor? Need a tutorial? Click Here
Want data assets? Click Here
You can modify attributes simply by adding stacks of the attribute behaviour to the unit. Like wise the stack count of the attribute behaviour is the quantity of that attribute.
I would recommend avoiding attributes. Professional design analysis has shown that attributes are nothing more than UI clutter and complicate mechanics. Practically everything done by an attribute can be applied directly to the unit in a way that is both simpler and more clear. For example instead of raising strength by 30% it could add 30% more health.
Avoid excessive use of catalog natives. At one stage they leaked quite badly (not sure if they patched that yet or not).