aurycat / UdonPortals

VRChat prefab that lets you create visual portals in VRChat worlds that can be looked through, walked through, & fallen through.
MIT License
23 stars 1 forks source link

User unable to walk through portals via point and click walking. #4

Open Chdata opened 2 weeks ago

Chdata commented 2 weeks ago

It seems if you walk into a portal using a point and click mode in VR, you can't go through them.

I'm not sure if this is fixable, but here is a nice video showcasing what happens with my friend explaining what movement mode they're using.

I guess it's because that movement mode is actually teleporting the player disconnected from their actual tracking.

https://youtu.be/fAYL3mNbmPQ

aurycat commented 2 weeks ago

Ooooh, that's really interesting... I never thought of that issue. Well, unfortunately, I don't think there's really anything I can do about it :( Like, even if I could detect the situation somehow and teleport the player (which I'm not sure if I can), either I

  1. Teleport the avatar but leave the 3rd person view where it is, meaning that now you can't see your avatar anymore,
  2. Teleport the avatar and the 3rd person view relative to the avatar, but that might cause the new position of the 3rd person view to be behind a wall or something like that.

The only way I could see this working is if, when the avatar goes through the portal, it teleports the player and then exits the holoport mode, so that the player's view is back where their avatar is. I'm not aware of any way to do that.

Sorry :( I think the best I can do is put a notice in the README saying it doesn't work for players in holoport mode.

Superbstingray commented 2 weeks ago

https://github.com/user-attachments/assets/b2adc06d-7139-4341-b553-19c5ceca9092

You can check the distance between the viewpoint and the head bone to determine if the player is holoporting. Then teleport using the avatar's root and AlignPlayer, rather than origin and AlignRoom. The player doesn't need to exit or be exited from holoport mode and can continue locomoting uninterrupted.

Updated PortalBehaviour holoport fix

aurycat commented 1 week ago

@Superbstingray Oooh! Very cool, awesome work! I should have had more confidence in the possibility of fixing anything with enough jankiness 😄 Do you mind please putting the holoport fix in another PR than your stereo separation one? I would like to inspect the two issues/code separately. I'm still not entirely sure about the stereo separation fix, but I'll post more on that PR.