|
Arma Reforger Script API
|
Public Member Functions | |
| proto external IEntity | GetOwner () |
| proto external void | Throw (vector vDirection, float fSpeedScale) |
| performs throwing | |
| proto external int | GetDefaultWeaponIndex () |
| proto external BaseWeaponComponent | GetCurrent () |
| Returns currently selected weapon or null if none. (This can either be a weapon component directly or a slot component.) | |
| proto external BaseWeaponComponent | GetCurrentWeapon () |
| proto external BaseWeaponComponent | GetCurrentGrenade () |
| proto external WeaponSlotComponent | GetCurrentSlot () |
| proto external GrenadeSlotComponent | GetCurrentGrenadeSlot () |
| proto external SightsComponent | GetCurrentSights () |
| proto external int | GetCurrentSightsIndex () |
| proto external bool | SelectWeapon (BaseWeaponComponent weapon) |
| Select the weapon passed by the parameter. | |
| proto external IEntity | SetSlotWeapon (WeaponSlotComponent pSlot, IEntity pWeaponEntity) |
| Returns the old weapon entity of the specified weapon slot. | |
| proto external bool | HasAnotherSelectableWeapon () |
| Returns false if there's no weapon that this manager can select other than the one that's already selected. | |
| proto external void | SetVisibleAllWeapons (bool state) |
| weapons visibility | |
| proto external void | SetVisibleCurrentWeapon (bool state) |
| proto external int | GetWeaponsSlots (out notnull array< WeaponSlotComponent > outSlots) |
| Returns the list of slots. | |
| proto external int | GetWeapons (out notnull array< BaseWeaponComponent > outWeapons) |
| Returns the list of weapons. | |
| proto external int | GetWeaponsList (out notnull array< IEntity > outWeapons) |
| Returns the list of weapons. | |
| proto external bool | GetCurrentMuzzleTransform (vector outMatrix[4]) |
| Returns true if current weapon is valid and outputs current weapon's muzzle transformation to the given matrix. | |
| proto bool | GetCurrentSightsTransform (out vector outWorldMatrix[4], out vector outLocalMatrix[4], out float fov) |
| Returns true if current weapon is valid and has some sights data, outputs sights transformation and fov. | |
| proto bool | GetCurrentSightsCameraTransform (out vector outLocalMatrix[4], out float fov) |
| Returns true if current weapon is valid and has some sights data, outputs local sights transformation with adjusted roll angle and fov. | |
Public Member Functions inherited from GameComponent | |
| bool | OnTicksOnRemoteProxy () |
Public Attributes | |
| ref ScriptInvoker< BaseWeaponComponent > | m_OnWeaponChangeCompleteInvoker = new ScriptInvoker<BaseWeaponComponent>() |
| ref ScriptInvoker< BaseWeaponComponent > | m_OnWeaponChangeStartedInvoker = new ScriptInvoker<BaseWeaponComponent>() |
Protected Member Functions | |
| void | OnWeaponChangeComplete (BaseWeaponComponent newWeaponSlot) |
| void | OnWeaponChangeStarted (BaseWeaponComponent newWeaponSlot) |
| proto external BaseWeaponComponent BaseWeaponManagerComponent.GetCurrent | ( | ) |
Returns currently selected weapon or null if none. (This can either be a weapon component directly or a slot component.)
| proto external BaseWeaponComponent BaseWeaponManagerComponent.GetCurrentGrenade | ( | ) |
| proto external GrenadeSlotComponent BaseWeaponManagerComponent.GetCurrentGrenadeSlot | ( | ) |
| proto external bool BaseWeaponManagerComponent.GetCurrentMuzzleTransform | ( | vector | outMatrix[4] | ) |
Returns true if current weapon is valid and outputs current weapon's muzzle transformation to the given matrix.
| proto external SightsComponent BaseWeaponManagerComponent.GetCurrentSights | ( | ) |
| proto bool BaseWeaponManagerComponent.GetCurrentSightsCameraTransform | ( | out vector | outLocalMatrix[4], |
| out float | fov ) |
Returns true if current weapon is valid and has some sights data, outputs local sights transformation with adjusted roll angle and fov.
| proto external int BaseWeaponManagerComponent.GetCurrentSightsIndex | ( | ) |
| proto bool BaseWeaponManagerComponent.GetCurrentSightsTransform | ( | out vector | outWorldMatrix[4], |
| out vector | outLocalMatrix[4], | ||
| out float | fov ) |
Returns true if current weapon is valid and has some sights data, outputs sights transformation and fov.
| proto external WeaponSlotComponent BaseWeaponManagerComponent.GetCurrentSlot | ( | ) |
| proto external BaseWeaponComponent BaseWeaponManagerComponent.GetCurrentWeapon | ( | ) |
| proto external int BaseWeaponManagerComponent.GetDefaultWeaponIndex | ( | ) |
| proto external IEntity BaseWeaponManagerComponent.GetOwner | ( | ) |
| proto external int BaseWeaponManagerComponent.GetWeapons | ( | out notnull array< BaseWeaponComponent > | outWeapons | ) |
Returns the list of weapons.
These can be either slots or weapons.
| outWeapons | The array with all weapons managed by this manager. |
| proto external int BaseWeaponManagerComponent.GetWeaponsList | ( | out notnull array< IEntity > | outWeapons | ) |
Returns the list of weapons.
| outWeapons | The array where all weapons will be inserted. |
| proto external int BaseWeaponManagerComponent.GetWeaponsSlots | ( | out notnull array< WeaponSlotComponent > | outSlots | ) |
Returns the list of slots.
| outSlots | The array where all slots will be inserted. |
| proto external bool BaseWeaponManagerComponent.HasAnotherSelectableWeapon | ( | ) |
Returns false if there's no weapon that this manager can select other than the one that's already selected.
|
protected |
|
protected |
| proto external bool BaseWeaponManagerComponent.SelectWeapon | ( | BaseWeaponComponent | weapon | ) |
Select the weapon passed by the parameter.
Returns true if the weapon has been selected. IMPORTANT* This is not synchronized in multiplayer, it will only replicate during streams-in correctly. You will need to implement your RPC to send this command to every client.
| proto external IEntity BaseWeaponManagerComponent.SetSlotWeapon | ( | WeaponSlotComponent | pSlot, |
| IEntity | pWeaponEntity ) |
Returns the old weapon entity of the specified weapon slot.
| proto external void BaseWeaponManagerComponent.SetVisibleAllWeapons | ( | bool | state | ) |
weapons visibility
| proto external void BaseWeaponManagerComponent.SetVisibleCurrentWeapon | ( | bool | state | ) |
| proto external void BaseWeaponManagerComponent.Throw | ( | vector | vDirection, |
| float | fSpeedScale ) |
performs throwing
| ref ScriptInvoker<BaseWeaponComponent> BaseWeaponManagerComponent.m_OnWeaponChangeCompleteInvoker = new ScriptInvoker<BaseWeaponComponent>() |
| ref ScriptInvoker<BaseWeaponComponent> BaseWeaponManagerComponent.m_OnWeaponChangeStartedInvoker = new ScriptInvoker<BaseWeaponComponent>() |