User Tools

Site Tools


modding:xml:overlaytype

This is an old revision of the document!


Table of Contents

Overview

<OverlayType> defines a type of attachment or enhancement to space object instances. For example, the pteravore attack which attaches on to a ship and drains fuel is implemented as an OverlayType.

Basic Attributes

UNID= The UNID of this type.

Events

An overlay instance has the following events:

<OnCreate>

  • gSource: The object that has the overlay.
  • aOverlayID: The ID of the overlay being created.

<OnDamage>

This event is called when the overlay is hit. The following variables are defined.

  • gSource: The object that has the overlay.
  • aOverlayID: The ID of the overlay.
  • aArmorSeg: The armor segment hit on the object.
  • aAttacker: The object that fired the shot that hit us.
  • aCause: The object that hit us (generally the projectile object).
  • aDamageHP: The amount of damage (in hit points) that reached us.
  • aDamageType: The type of damage.
  • aHitDir: The angle from which the attack came.
  • aHitPos: The position where we were hit (in global coordinates).
  • aOrderGiver: The object that ordered the attack on us. This is generally the same as aAttacker but if an auton attacked us, this will be the controller of the auton (e.g., the player).
  • aWeaponType: The UNID of the weapon used.

<OnDestroy>

This event is called when the overlay is destroyed.

  • gSource: The object that has the overlay.
  • aOverlayID: The ID of the overlay being created.

<OnUpdate>

An overlay gets this event every 15 ticks.

  • gSource: The object that has the overlay.
  • aOverlayID: The ID of the overlay being created.
modding/xml/overlaytype.1369972259.txt.gz · Last modified: 2014/12/27 04:40 (external edit)