LuaDocs/HeldDevice

From Data Realms Wiki

Revision as of 06:03, 13 May 2011 by LuaBot (Talk | contribs)
Jump to: navigation, search

Contents

Parent: Attachable

Concrete Class. An articulated device that can be weilded by an Actor.

Go back to Class Index


Properties

ClassName

The class name of this Entity.A string with the friendly-formatted type name of this object.

SupportPos

Read-only property. The absolute position of the support handhold that this HeldDevice offers.A vector describing the absolute world coordinates for the support position of this HeldDevice.

MagazinePos

Read-only property. The absolute position of the magazine or other equivalent point of this.A vector describing the absolute world coordinates for the magazine attachment point of this

MuzzlePos

Read-only property. The absolute position of the muzzle or other equivalent point of this.A vector describing the absolute world coordinates for the muzzle point of this

MuzzleOffset

Read-only property. The unrotated relative offset from the position to the muzzle or other equivalent point of this.A unrotated vector describing the relative for the muzzle point of this from this' position.

StanceOffset

Read-only property. The current position offset of this HeldDevice's joint relative from the parent Actor's position, if attached.A const reference to the current stance parent offset.

SharpLength

Gets how much farther an Actor which holds this device can see when aiming this HeldDevice sharply.The length in world pixel units.


Functions

IsWeapon

Indicates whether this is an offensive weapon or not.

Arguments:

  • None.

Return value:

Offensive weapon or not.


IsTool

Indicates whether this is a tool or not.

Arguments:

  • None.

Return value:

Tool or not.


IsShield

Indicates whether this is a shield or not.

Arguments:

  • None.

Return value:

Shield or not.


IsOneHanded

Indicates whether this can be held and operated effectively with one hand or not.

Arguments:

  • None.

Return value:

One handed device or not.


Activate

Activates one of this HDFirearm's features. Analogous to 'pulling the trigger'.

Arguments:

  • None.

Return value:

None.


Deactivate

Deactivates one of this HDFirearm's features. Analogous to 'releasing the trigger'.

Arguments:

  • None.

Return value:

None.


Reload

Throws out the currently used Magazine, if any, and puts in a new one after the reload delay is up.

Arguments:

  • None.

Return value:

None.


IsActivated

Tells whether the device is curtrently being activated.

Arguments:

  • None.

Return value:

Whether being activated.


IsReloading

Tells whether the device is curtrently being reloaded.

Arguments:

  • None.

Return value:

Whetehr being reloaded.


DoneReloading

Tells whether the device just finished reloading this frame.

Arguments:

  • None.

Return value:

Whether just done reloading this frame.


NeedsReloading

Tells whether the device is curtrently in need of being reloaded.

Arguments:

  • None.

Return value:

Whetehr in need of reloading (ie not full).


IsFull

Tells whether the device is curtrently full and reloading won't have any effect.

Arguments:

  • None.

Return value:

Whetehr magazine is full or not.


Go back to Class Index

Personal tools