mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 05:23:09 +02:00
use slot to change AvatarData::_sessionUUID
This commit is contained in:
parent
2f97dd2574
commit
4b306401af
2 changed files with 2 additions and 6 deletions
|
@ -232,6 +232,7 @@ Application::Application(int& argc, char** argv, timeval &startup_time) :
|
||||||
connect(nodeList, SIGNAL(nodeAdded(SharedNodePointer)), &_voxels, SLOT(nodeAdded(SharedNodePointer)));
|
connect(nodeList, SIGNAL(nodeAdded(SharedNodePointer)), &_voxels, SLOT(nodeAdded(SharedNodePointer)));
|
||||||
connect(nodeList, SIGNAL(nodeKilled(SharedNodePointer)), &_voxels, SLOT(nodeKilled(SharedNodePointer)));
|
connect(nodeList, SIGNAL(nodeKilled(SharedNodePointer)), &_voxels, SLOT(nodeKilled(SharedNodePointer)));
|
||||||
connect(nodeList, &NodeList::uuidChanged, this, &Application::updateWindowTitle);
|
connect(nodeList, &NodeList::uuidChanged, this, &Application::updateWindowTitle);
|
||||||
|
connect(nodeList, SIGNAL(uuidChanged(const QUuid&)), _myAvatar, SLOT(setSessionUUID(const QUuid&)));
|
||||||
connect(nodeList, &NodeList::limitOfSilentDomainCheckInsReached, nodeList, &NodeList::reset);
|
connect(nodeList, &NodeList::limitOfSilentDomainCheckInsReached, nodeList, &NodeList::reset);
|
||||||
|
|
||||||
// connect to appropriate slots on AccountManager
|
// connect to appropriate slots on AccountManager
|
||||||
|
@ -1216,11 +1217,6 @@ void Application::timer() {
|
||||||
|
|
||||||
// ask the node list to check in with the domain server
|
// ask the node list to check in with the domain server
|
||||||
NodeList::getInstance()->sendDomainServerCheckIn();
|
NodeList::getInstance()->sendDomainServerCheckIn();
|
||||||
|
|
||||||
// as soon as we have a valid sessionUUID, store it in the avatar for reference
|
|
||||||
if (_myAvatar->getSessionUUID().isNull()) {
|
|
||||||
_myAvatar->setSessionUUID(NodeList::getInstance()->getSessionUUID());
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::idle() {
|
void Application::idle() {
|
||||||
|
|
|
@ -102,7 +102,6 @@ public:
|
||||||
virtual ~AvatarData();
|
virtual ~AvatarData();
|
||||||
|
|
||||||
const QUuid& getSessionUUID() { return _sessionUUID; }
|
const QUuid& getSessionUUID() { return _sessionUUID; }
|
||||||
void setSessionUUID(const QUuid& id) { _sessionUUID = id; }
|
|
||||||
|
|
||||||
const glm::vec3& getPosition() const { return _position; }
|
const glm::vec3& getPosition() const { return _position; }
|
||||||
void setPosition(const glm::vec3 position) { _position = position; }
|
void setPosition(const glm::vec3 position) { _position = position; }
|
||||||
|
@ -225,6 +224,7 @@ public slots:
|
||||||
void sendBillboardPacket();
|
void sendBillboardPacket();
|
||||||
void setBillboardFromNetworkReply();
|
void setBillboardFromNetworkReply();
|
||||||
void setJointMappingsFromNetworkReply();
|
void setJointMappingsFromNetworkReply();
|
||||||
|
void setSessionUUID(const QUuid& id) { _sessionUUID = id; }
|
||||||
protected:
|
protected:
|
||||||
QUuid _sessionUUID;
|
QUuid _sessionUUID;
|
||||||
glm::vec3 _position;
|
glm::vec3 _position;
|
||||||
|
|
Loading…
Reference in a new issue