@RaananW thanks for fixing the teleportation “sticking” issue! That was really bothering me and I was about to ask in here about that but did a search first and saw a github issue investigation about it with 4.2 milestone. I upgraded my cdn to use preview and bam! Works like a charm now in Oculus Quest. Thanks so much!
If I’m nitpicking, I wonder if the following things can be easily tweaked/configured?
The arc rendering only kicks in when trying to teleport very far away. If I teleport any closer, I don’t see an arc I only see a straight line to the target circle which is not as pretty. In fact the arc only shows up when I lift up a controller to about 40-45 degrees above horizontal. Is there a way to make this configurable? In some games that I play I see the teleportation arc rendering for even 1 or 2 meters away, which I like. And in those games they render smaller arcs instead of the extremely high parabola that is currently rendered by Babylonjs teleporation.
In my experience the target circle being drawn is bit big. Any thoughts on allowing options to change the radius of the circle?
Is it possible to have no color for the circle fill?
Is there a way to adjust the arc color or arc thickness?
I feel like if I disable the rotation-while-teleporting feature, then maybe the arrow mesh should just be removed/hidden entirely as well since I don’t care so much about the direction, only the location.
It sometimes seems like I don’t teleport completely to the location I specified. I’m just a few feet shy of getting there, like 98%. Though, this is minor and might be because the circle being drawn is too big and I’m not accurate at picking my destination.
I had it configured exactly the other way - the parabolic (arc) ray only triggers as a secondary ray is the main (direct) ray couldnt find anything (In your case, in an angle > 45). This was done because we keep backwards compatibility, and this was the WebVR behavior. However! I like the idea very much of having the arc ray the main ray and ignore the direct ray. I guess I won’t make it for 4.2, but I have no problem adding it to the lit of improvements to be done.
You can fully configure the ring mesh yourself. But that would require you creating your own mesh andprovide it with teleportationTargetMesh option. The mesh is exposed in the options object you provide to the teleportation feature (unless using the default configuration). I can try exposing the object in a different way, would be a part of the improvements
No color meaning transparent?
The Arc is a line mesh, and a line mesh has a specific thickness. But I just noticed I forgot to update the lines mesh on each frame (it creates a new one every frame), so thanks for making me look at the code again! If you do want a different mesh I can try providing a function to create the mesh istead of the way I am creating it.
Sure! Makes sense. Part of the above mentioned improvements
That’s interesting. You mean that the ring is in the right place but you land somewhere else? I very much like to see an example of that, as this should never happen. Might it be that you are trying to teleport beyond the ground mesh?
Cool. Yes, in my experience playing games on the Oculus Quest: The Starwars games, Arizona Sunshine, BigScreen etc. The emerging convention seems to be displaying an arc for where you want to go. I don’t recall seeing a straight ray being very popular for teleportation, at least I haven’t see it. In Babylonjs was my first time seeing it done that way.
I think a circle is fine. I wasn’t thinking to completely customize the mesh. If it is possible to expose the circle radius to the default options that might suffice.
Yes, or allow color with opacity. Hmm… is that possible already? I haven’t tried it, but can we do something like set css color with alpha? rgba(255, 0, 0, 0.4);
Thanks. Replacing the mesh sounds like an advanced capability. Although nice, some simple default options for being able to change the arc-color/arc-opacity and perceived “thickness” of the arc would go a long way without having to completely write our own.
Ah, I suppose we can hide this ourselves if we can set the opacity of the rotation mesh to zero? It just made sense to me that if rotation is disabled, this goes hand in hand with hiding the rotation gizmo since I thought that mesh existed only for me to also see what direction I’m going to be in.
I don’t have precise data, it’s my subjective perception that the teleportation “could be more accurate”, but maybe if the maths are accurate then I’m the one that’s wrong? But maybe if you have a chance you can try teleporting to the corner of a plane and try to position yourself as accurately as you can as if you want to stand on it’s very corner edge looking down. For me, sometimes, instead of looking down and seeing the precise corner of the plane where I placed my arc and target circle, instead I see I’m about 2-3 feet behind that area and I need to teleport a little bit more to refine my placement. I never overshoot a target, when/if this happens I undershoot and need to go a little bit further if that makes sense.
HI @RaananW I saw your PR was merged with a checked mark in the description re: “Allow making parabolic teleportation the main one”. That’s exciting. Does that mean we’ll soon be able to see an arc for short distances instead of the current straight ray? I just checked a random webxr enabled playground yesterday and it still appears to use a straight ray. When would I be able to test an arc rendered as the default?
Additional thoughts for improvements:
Is there a way to dynamically limit the teleportation distance? It’s useful for only allowing players to move in small increments when in close combat like 3-5 meters instead of a huge distance like 50 meters. Additionally it could be useful to change this dynamically during game play if under certain game circumstances you are allowed to teleport further.
It would be useful to display a “teleportation denied” arc that shows up in red, where the user is not allowed to teleport. This is useful feed back in a game like Arizona Sunshine where you can see teleportation arc is working, in that you can see it, but you aren’t allowed to use it right now because you are being attacked. (hubs.mozilla also does something similar by showing a green arc where teleportation is allowed.). A parameter that allows denying teleportation dynamically based on a custom function would be useful for keeping players close to each other in a scene rather than having them run too far away from each other.
What I’m noticing is that the parabola unexpectedly arcs underneath the target instead of over the target spot for short distances. And assigning a number like 1 or 2 to parabolicCheckRadius, attempting to limit traveling to 1 or 2 meters per teleport does not appear to restrict anything for me. The arc still can be cast a great distance longer than that. Should I expect to see the parabola only cast up to 1 or 2 meters away if that property is set?
Assigned myself and will find the time to check that.
regarding the “under” arc - this is actually a feature. If you have straight-line disabled you will not see it, but the ray sent by the teleportation will always try to “find its way” to the ground, which it clearly does now. I guess you expect the line to find the floor nearer you from above?
That’s true, it does “find it’s way” to the ground. I guess I expected that when straight line is disabled that the arc would always cast as a rainbow shape or upside down parabola, be it shorter or longer or nearly straight based on distance, but always slightly curved downward. To me, it’s a bit odd to curve the other way and gives me the confusing impression that the floor is transparent and I’m seeing the ray come from beneath the floor.