So, I’ve been working on a chair that works for any height, and while it works basically flawlessly locally, I’m having a really hard time getting it to work over the network.
The chair works by grabbing the positions of the player’s left foot bone and hip bone, then it uses those positions to calculate how much the seat needs to move up, down, forwards and backwards. It also references another gameObject that it uses as an anchor, it ended up being roughly where the players knees would be. It then moves the seat and the player sits almost perfectly on the seat.
Now, that all works fine locally, but to get it to work over network is proving to be another challenge entirely. First, I made a public value for both chair height and chair forwardness, and then made an event that re-calibrates for everyone, but it seems that it doesn’t update for others… except it does for one person and that one person seems to be a different random person for each person in the lobby. It seems to me that the synced values aren’t being applied globally, so I tried adding a ‘set owner’ to it to try and sync the values to the player that’s sitting, but that doesn’t seem to help. I added a testing cube that moves up and down according to the seat, and that doesn’t move an inch whenever it fails.
Here’s a look at the code. I also converted it to udon# to see if it would help me notice something I was missing, but that didn’t help.
Heck, here’s a download to if that helps:
Also, I don’t mind at all if you share the completed project and all (credit would be nice though). Also, if someone else has already made something like this, please don’t hesitate to share