Signal1
Signal support.
XRNode3D.swift:307class Signal1
Use the connect(flags:_:)
method to connect to the signal on the container object, and disconnect(_:)
to drop the connection.
You can also await the emitted
property for waiting for a single emission of the signal.
Other members in extension
View members
Hide members
This section is hidden by default because it contains too many (9) members.
Type members
Instance members
var pose: StringName
The name of the pose we’re bound to. Which poses a tracker supports is not known during design time.
var showWhenTracked: Bool
Enables showing the node when tracking starts, and hiding the node when tracking is lost.
var tracker: StringName
The name of the tracker we’re bound to. Which trackers are available is not known during design time.
var trackingChanged: Signal1
Emitted when the
tracker
starts or stops receiving updated tracking data for thepose
being tracked. Thetracking
argument indicates whether the tracker is getting updated tracking data.func getHasTrackingData(
) -> Bool Returns
true
if thetracker
has current tracking data for thepose
being tracked.func getIsActive(
) -> Bool Returns
true
if thetracker
has been registered and thepose
is being tracked.func getPose(
) -> XRPose? Returns the
XRPose
containing the current state of the pose being tracked. This gives access to additional properties of this pose.func triggerHapticPulse(actionName: String, frequency: Double, amplitude: Double, durationSec: Double, delaySec: Double
) Triggers a haptic pulse on a device associated with this interface.
Citizens in SwiftGodot
Instance members
var emitted: Void
You can await this property to wait for the signal to be emitted once
func connect(flags: Object.ConnectFlags, @escaping (_ tracking: Bool) -> ()
) -> Object Connects the signal to the specified callback
func disconnect(Object
) Disconnects a signal that was previously connected, the return value from calling
connect(flags:_:)