mirror of
https://github.com/overte-org/overte.git
synced 2025-08-04 08:43:47 +02:00
CR Fixes
This commit is contained in:
parent
6317ceb9b3
commit
6cb12daf74
1 changed files with 13 additions and 8 deletions
|
@ -67,6 +67,11 @@ AvatarManager::AvatarManager(QObject* parent) :
|
||||||
connect(nodeList.data(), &NodeList::ignoredNode, this, [this](const QUuid& nodeID, bool enabled) {
|
connect(nodeList.data(), &NodeList::ignoredNode, this, [this](const QUuid& nodeID, bool enabled) {
|
||||||
if (enabled) {
|
if (enabled) {
|
||||||
removeAvatar(nodeID, KillAvatarReason::AvatarIgnored);
|
removeAvatar(nodeID, KillAvatarReason::AvatarIgnored);
|
||||||
|
} else {
|
||||||
|
auto avatar = std::static_pointer_cast<Avatar>(getAvatarBySessionID(nodeID));
|
||||||
|
if (avatar) {
|
||||||
|
avatar->createOrb();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -392,14 +397,14 @@ void AvatarManager::simulateAvatarFades(float deltaTime) {
|
||||||
}
|
}
|
||||||
|
|
||||||
AvatarSharedPointer AvatarManager::newSharedAvatar(const QUuid& sessionUUID) {
|
AvatarSharedPointer AvatarManager::newSharedAvatar(const QUuid& sessionUUID) {
|
||||||
return AvatarSharedPointer(new OtherAvatar(qApp->thread()), [sessionUUID](OtherAvatar* ptr) {
|
|
||||||
ptr->deleteLater();
|
auto otherAvatar = new OtherAvatar(qApp->thread());
|
||||||
ptr->setSessionUUID(sessionUUID);
|
otherAvatar->setSessionUUID(sessionUUID);
|
||||||
auto nodeList = DependencyManager::get<NodeList>();
|
auto nodeList = DependencyManager::get<NodeList>();
|
||||||
if (!nodeList || !nodeList->isIgnoringNode(sessionUUID)) {
|
if (!nodeList || !nodeList->isIgnoringNode(sessionUUID)) {
|
||||||
ptr->createOrb();
|
otherAvatar->createOrb();
|
||||||
}
|
}
|
||||||
});
|
return AvatarSharedPointer(otherAvatar, [](OtherAvatar* ptr) { ptr->deleteLater(); });
|
||||||
}
|
}
|
||||||
|
|
||||||
void AvatarManager::queuePhysicsChange(const OtherAvatarPointer& avatar) {
|
void AvatarManager::queuePhysicsChange(const OtherAvatarPointer& avatar) {
|
||||||
|
|
Loading…
Reference in a new issue