WeaponEntry

Members

Member

Description

distance

isUsableByAi

mainWeaponRole

The main weapon role generated from the weapon’s stats

name

prefab

prefabWeapon

slot

tags

The list of weapon tags, such as Assault, Marksman etc.

type

uiSprite

Methods

Method

Description

HasTag(tag)

Returns true if the weapon entry has the tag (case insensitive)

InstantiateImposter(position, rotation)

Instantiates an imposter object of the weapon prefab.

ToString()

Details

class WeaponEntry
const Distance distance
const bool isUsableByAi
const WeaponRole mainWeaponRole

The main weapon role generated from the weapon’s stats

const string name
const GameObject prefab
const Weapon prefabWeapon
const WeaponSlot slot
const array<string> tags

The list of weapon tags, such as Assault, Marksman etc.

const LoadoutType type
const Sprite uiSprite
bool HasTag(string tag)

Returns true if the weapon entry has the tag (case insensitive)

GameObject InstantiateImposter(Vector3 position, Quaternion rotation)

Instantiates an imposter object of the weapon prefab. The imposter object contains the third person transform of the weapon prefab, and has its Weapon component culled. If the weapon doesn’t have a third person transform, this function will fail and return nil.

string ToString()