mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-19 10:18:43 +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(nodeKilled(SharedNodePointer)), &_voxels, SLOT(nodeKilled(SharedNodePointer)));
|
||||
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 to appropriate slots on AccountManager
|
||||
|
@ -1216,11 +1217,6 @@ void Application::timer() {
|
|||
|
||||
// ask the node list to check in with the domain server
|
||||
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() {
|
||||
|
|
|
@ -102,7 +102,6 @@ public:
|
|||
virtual ~AvatarData();
|
||||
|
||||
const QUuid& getSessionUUID() { return _sessionUUID; }
|
||||
void setSessionUUID(const QUuid& id) { _sessionUUID = id; }
|
||||
|
||||
const glm::vec3& getPosition() const { return _position; }
|
||||
void setPosition(const glm::vec3 position) { _position = position; }
|
||||
|
@ -225,6 +224,7 @@ public slots:
|
|||
void sendBillboardPacket();
|
||||
void setBillboardFromNetworkReply();
|
||||
void setJointMappingsFromNetworkReply();
|
||||
void setSessionUUID(const QUuid& id) { _sessionUUID = id; }
|
||||
protected:
|
||||
QUuid _sessionUUID;
|
||||
glm::vec3 _position;
|
||||
|
|
Loading…
Reference in a new issue