summaryrefslogtreecommitdiff
path: root/modules/webxr
diff options
context:
space:
mode:
authorFabio Alessandrelli <fabio.alessandrelli@gmail.com>2021-01-10 11:03:50 +0100
committerFabio Alessandrelli <fabio.alessandrelli@gmail.com>2021-01-10 12:04:09 +0100
commiteb5304842ab566d5c5a53e01c60d532d016971c8 (patch)
treecc43d930b0a93bb942b51d62755ab3d758bc7e8c /modules/webxr
parent88300af7e48ad50072359136706934cac88f471d (diff)
Fix WebXR module.
Some functions and enums were renamed in 4.0 but not updated in the WebXR code.
Diffstat (limited to 'modules/webxr')
-rw-r--r--modules/webxr/webxr_interface_js.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/webxr/webxr_interface_js.cpp b/modules/webxr/webxr_interface_js.cpp
index 72dc4790ac..6594553146 100644
--- a/modules/webxr/webxr_interface_js.cpp
+++ b/modules/webxr/webxr_interface_js.cpp
@@ -375,11 +375,11 @@ void WebXRInterfaceJS::_update_tracker(int p_controller_id) {
if (godot_webxr_is_controller_connected(p_controller_id)) {
if (tracker == nullptr) {
tracker = memnew(XRPositionalTracker);
- tracker->set_type(XRServer::TRACKER_CONTROLLER);
+ tracker->set_tracker_type(XRServer::TRACKER_CONTROLLER);
// Controller id's 0 and 1 are always the left and right hands.
if (p_controller_id < 2) {
- tracker->set_name(p_controller_id == 0 ? "Left" : "Right");
- tracker->set_hand(p_controller_id == 0 ? XRPositionalTracker::TRACKER_LEFT_HAND : XRPositionalTracker::TRACKER_RIGHT_HAND);
+ tracker->set_tracker_name(p_controller_id == 0 ? "Left" : "Right");
+ tracker->set_tracker_hand(p_controller_id == 0 ? XRPositionalTracker::TRACKER_HAND_LEFT : XRPositionalTracker::TRACKER_HAND_RIGHT);
}
// Use the ids we're giving to our "virtual" gamepads.
tracker->set_joy_id(p_controller_id + 100);