Version 16 (modified by fatherbushido, 7 years ago) ( diff )

add player type aura

The auras can be used on an entity by creating an aura json like this:

{
    type: range,
    radius: 60,
    affects: ["Worker"],
    modifications: [
        {value: "Builder/Rate", multiply: 1.15}
    ],
    auraName: "Builder Aura",
    auraDescription: "Buildings construct 15% faster within his vision.",
    overlayIcon: "art/textures/ui/session/auras/build_bonus.png"
}

The type can currently be range, global, player, formation, garrison or garrisonedUnits. The range type also requires an extra Radius (as in the example), all entities in this radius will be affected by the aura. Global auras work on all entities (like technologies, but the working is reverted when the entity with an aura dies). Global and range auras also affect the unit itself when applicable. Player aura affects the Player entity. Formation auras affect all members of the same formation as the unit. The garrison aura has an effect on the garrisoning structure (arrows the structure shoots, speed of a ship, ...). And as last one, the garrisonedUnits aura influences the units that are visibly garrisoned (giving units on a wall extra armor f.e.).

affects determines the classes it affects, listed as ["Class1 Class2", "Class3"], which means the target needs to have (Class1 AND Class2) OR Class3 to benefit from the aura.

affectedPlayers defines on which players it will act (a hero might cause the enemy to have less armour), listed as ["Value1", "Value2"]. The possible values are Player (yourself), Ally, ExclusiveAlly, MutualAlly, ExclusiveMutualAlly or Enemy. This value defaults to [ "Player" ] .

modifications are list of modifications that will be applied. Similarly structured as with technologies. A modification consists out of key, which presents the name of the value that will be changed, and either add or multiply to resp. add or multiply the value of the affected entity with something. Note that the actions should be reversible (they are reversed when the aura carrying entity is killed), so multiplications with 0 are not allowed. All other values are supported.

The list of modifiable unit properties is the same as with the Technologies (see TechModifications).

auraName and auraDescription are not mandatory, but will appear in various UI elements.

overlayIcon is the icon showed above all affected entity's.

requiredTechnology is a technology required for the aura to be available.

stackable is an optional boolean which allow the aura to be stackable when set to true.

Note: See TracWiki for help on using the wiki.