mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-18 13:57:05 +02:00
Prevent 2 avatars from staying seated in the same chair
This commit is contained in:
parent
4c75680877
commit
eccc9ff47c
1 changed files with 7 additions and 1 deletions
|
@ -156,7 +156,10 @@
|
|||
MyAvatar.removeAnimationStateHandler(this.animStateHandlerID);
|
||||
Script.update.disconnect(this, this.update);
|
||||
|
||||
this.setSeatUser(null);
|
||||
if (MyAvatar.sessionUUID === this.getSeatUser()) {
|
||||
this.setSeatUser(null);
|
||||
}
|
||||
|
||||
if (Settings.getValue(SETTING_KEY) === this.entityID) {
|
||||
Settings.setValue(SETTING_KEY, "");
|
||||
|
||||
|
@ -261,6 +264,9 @@
|
|||
shouldStandUp = true;
|
||||
}
|
||||
|
||||
if (MyAvatar.sessionUUID !== this.getSeatUser()) {
|
||||
shouldStandUp = true;
|
||||
}
|
||||
|
||||
if (shouldStandUp || avatarDistance > RELEASE_DISTANCE) {
|
||||
print("IK error: " + ikError + ", distance from chair: " + avatarDistance);
|
||||
|
|
Loading…
Reference in a new issue