Class: MockCArtefact
Mock of the X-Ray engine artefact object.
Extends
MockCGameObject
Implements
CArtefact
Constructors
Constructor
new MockCArtefact(): MockCArtefact;Returns
MockCArtefact
Inherited from
MockCGameObject.constructorMethods
create()
static create(): MockCArtefact;Returns
MockCArtefact
Overrides
MockCGameObject.createmock()
static mock(): CArtefact;Returns
CArtefact
Overrides
MockCGameObject.mockProperties
__name
__name: string = "CGameObject";LuaBind instance constructor name.
Implementation of
CArtefact.__nameInherited from
MockCGameObject.__name_construct
_construct: MockedFunction<() => DLL_Pure>;Construct engine-side object state.
Remarks
Lifecycle hook used by the engine. Calling it from gameplay scripts can reinitialize native state unexpectedly.
Returns
Constructed base object.
Implementation of
CArtefact._constructInherited from
MockCGameObject._constructFollowByPath
FollowByPath: Mock<UnknownFunction>;Move the artefact detector helper along a patrol path.
Remarks
Native code delegates to detector support when it exists. Missing detector support makes this a no-op. The vector parameter is stored as movement force, not as an initial world position.
Param
path_name
Patrol path name.
Param
point_index
Starting path point index.
Param
position
Movement force used by detector support.
Implementation of
CArtefact.FollowByPathGetAfRank
GetAfRank: Mock<() => number>;Returns
Artefact rank used by detectors and inventory UI.
Implementation of
CArtefact.GetAfRankgetEnabled
getEnabled: MockedFunction<() => boolean>;Returns
Whether the object is enabled in the client object loop.
Implementation of
CArtefact.getEnabledInherited from
MockCGameObject.getEnabledgetVisible
getVisible: MockedFunction<() => boolean>;Returns
Whether the object is visible.
Implementation of
CArtefact.getVisibleInherited from
MockCGameObject.getVisiblenet_Export
net_Export: MockedFunction<(net_packet: net_packet) => void>;Export network state to a packet.
Param
net_packet
Destination network packet.
Implementation of
CArtefact.net_ExportInherited from
MockCGameObject.net_Exportnet_Import
net_Import: MockedFunction<(net_packet: net_packet) => void>;Import network state from a packet.
Param
net_packet
Source network packet.
Implementation of
CArtefact.net_ImportInherited from
MockCGameObject.net_Importnet_Spawn
net_Spawn: MockedFunction<(cse_abstract: cse_abstract) => boolean>;Spawn the client object from its server object.
Remarks
Lifecycle hook used during network spawn. Return false to reject spawn in custom subclasses.
Param
cse_abstract
Server object used for spawn data.
Returns
Whether spawn succeeded.
Implementation of
CArtefact.net_SpawnInherited from
MockCGameObject.net_SpawnSwitchVisibility
SwitchVisibility: Mock<UnknownFunction>;Show or hide the artefact detector helper.
Remarks
Native code delegates to detector support when it exists. Missing detector support makes this a no-op; it does not spawn or destroy the artefact object.
Param
is_visible
New visibility state.
Implementation of
CArtefact.SwitchVisibilityuse
use: MockedFunction<(object: CGameObject) => boolean>;Use another object through the engine interaction path.
Param
object
Object being used.
Returns
Whether the use action was handled.
Implementation of
CArtefact.useInherited from
MockCGameObject.useVisual
Visual: MockedFunction<() => IXR_IRender_Visual>;Returns
Render visual assigned to the object.
Implementation of
CArtefact.VisualInherited from
MockCGameObject.Visual