User Tools

Site Tools


modding:xml:api_version

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
modding:xml:api_version [2013/09/02 19:27] gpmmodding:xml:api_version [2014/12/27 04:40] – external edit 127.0.0.1
Line 16: Line 16:
  
 The following API versions are implemented: The following API versions are implemented:
 +====API Version 22====
 +Transcendence 1.3 and above.
  
 ====API Version 14==== ====API Version 14====
-**[IN PROGRESS]** 
 Transcendence 1.2 Beta 1 and above. Transcendence 1.2 Beta 1 and above.
  
 === Dynamic Effects === === Dynamic Effects ===
 +Dynamic effects are visual effects whose parameters are modified at runtime. A dynamic effect uses the <GetParameters> event on an <EventType> to dynamically set the effect parameters. For example:
  
 +  <EffectType UNID="..."
 +        instance="creator"
 +        >
 +     <Effect>
 +        <Ray
 +           style="..."
 +           ...
 +           >
 +           
 +           <Events>
 +              <GetParameters>
 +                 (block Nil
 +                    ...
 +              
 +                    {
 +                       length: ...
 +                       width: ...
 +                       intensity: ...
 +                       }
 +                    )
 +              </GetParameters>
 +           </Events>
 +        </Ray>
 +     </Effect>
 +  </EffectType>
 +
 +In the above example, the parameters for the <Ray> effect are being set by the <GetParameters> function, which returns a struct. Each field in the struct represents a parameter in the <Ray> element to be set.
 +
 +The **instance** parameter on <EffectType> defines when <GetParameters> is called to set the effect parameters. The valid instances are:
 +
 +  * creator: The effect parameters are defined each time the effect is created (e.g., when the weapon is fired).
 +  * game: The effect parameters are defined once at the beginning of the game and shared. For example, if multiple weapons use the same effect, all will use the same parameters.
 +  * owner: The effect parameters are defined once per effect owner. For example, if multiple weapons use the same effect, the effect will be defined separately for each weapon.
 +
 +NOTE: As of API version 14, only the <Ray> effect supports dynamic effects.
 +
 +=== Enhancement Devices ===
 +In previous APIs the <EnhancerDevice> element was used to define a device that could enhance other devices (weapons, shields, etc.) In API version 14 there is a new element, called <EnhancementAbilities> that may be added to any device class (e.g., a <Shields> device).
 +
 +The <EnhancementAbilities> element may contain zero or more <Enhance> sub-elements, each of which defines an enhancement conferred on other devices. The <Enhance> sub-element has the following parameters:
 +
 +  * type: This is a user-defined string representing the type of enhancement. Only a single enhancement of each type will be applied.
 +  * criteria: This is an item criteria specifying the set of devices that will be enhanced by this device.
 +  * enhancement: This defines the enhancement applied to the set of devices that match the criteria. This is expressed as an enhancement code (see shpEnhanceItem) or as one of the following special codes:
 +    * "+hpBonus:{n};" where {n} is the percent bonus.
 +    * "+shield:{n};" where {n} is a level. This is equivalent to the shield:{n} damage modifier.
 +    * "+speed:{n};" where {n} is the percent value of the new weapon delay time relative to the current one. E.g., 75 = 75% of the original delay time.
  
 === New Functions === === New Functions ===
modding/xml/api_version.txt · Last modified: 2017/01/16 19:42 by xephyr