mirror of
https://github.com/overte-org/overte.git
synced 2025-04-08 07:12:40 +02:00
Use avatar position as orb position when head position not available
This commit is contained in:
parent
afd7993152
commit
a2ac43289c
1 changed files with 5 additions and 1 deletions
|
@ -64,7 +64,11 @@ void OtherAvatar::removeOrb() {
|
|||
void OtherAvatar::updateOrbPosition() {
|
||||
if (!_otherAvatarOrbMeshPlaceholderID.isNull()) {
|
||||
EntityItemProperties properties;
|
||||
properties.setPosition(getHead()->getPosition());
|
||||
glm::vec3 headPosition;
|
||||
if (!_skeletonModel->getHeadPosition(headPosition)) {
|
||||
headPosition = getWorldPosition();
|
||||
}
|
||||
properties.setPosition(headPosition);
|
||||
DependencyManager::get<EntityScriptingInterface>()->editEntity(_otherAvatarOrbMeshPlaceholderID, properties);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue