mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-09 15:52:09 +02:00
write created as quint64
This commit is contained in:
parent
fa66ed766d
commit
4210d4a7cd
2 changed files with 2 additions and 10 deletions
|
@ -339,11 +339,6 @@ void EntityItemProperties::setBillboardModeFromString(const QString& materialMap
|
|||
}
|
||||
}
|
||||
|
||||
QString EntityItemProperties::getCreatedAsString() const {
|
||||
auto created = QDateTime::fromMSecsSinceEpoch(getCreated() / 1000.0f, Qt::UTC); // usec per msec
|
||||
return created.toString(Qt::ISODate);
|
||||
}
|
||||
|
||||
EntityPropertyFlags EntityItemProperties::getChangedProperties() const {
|
||||
EntityPropertyFlags changedProperties;
|
||||
|
||||
|
@ -1396,7 +1391,7 @@ QScriptValue EntityItemProperties::copyToScriptValue(QScriptEngine* engine, bool
|
|||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_DIMENSIONS, dimensions);
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_ROTATION, rotation);
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_REGISTRATION_POINT, registrationPoint);
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE_GETTER(PROP_CREATED, created, getCreatedAsString());
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_CREATED, created);
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_LAST_EDITED_BY, lastEditedBy);
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE_GETTER(PROP_ENTITY_HOST_TYPE, entityHostType, getEntityHostTypeAsString());
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_OWNING_AVATAR_ID, owningAvatarID);
|
||||
|
@ -1774,7 +1769,7 @@ void EntityItemProperties::copyFromScriptValue(const QScriptValue& object, bool
|
|||
COPY_PROPERTY_FROM_QSCRIPTVALUE(rotation, quat, setRotation);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE(registrationPoint, vec3, setRegistrationPoint);
|
||||
if (!honorReadOnly) {
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE_GETTER(created, QString, setCreatedFromString, getCreatedAsString);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE(created, quint64, setCreated);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE(lastEditedBy, QUuid, setLastEditedBy);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE_ENUM(entityHostType, EntityHostType);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE(owningAvatarID, QUuid, setOwningAvatarID);
|
||||
|
|
|
@ -382,9 +382,6 @@ public:
|
|||
|
||||
void setLocationDirty() { _positionChanged = true; _rotationChanged = true; }
|
||||
|
||||
void setCreatedFromString(QString& v) { _created = QDateTime::fromString(v.trimmed(), Qt::ISODate).toMSecsSinceEpoch() * 1000; }
|
||||
QString getCreatedAsString() const;
|
||||
|
||||
bool hasTransformOrVelocityChanges() const;
|
||||
void clearTransformOrVelocityChanges();
|
||||
bool hasMiscPhysicsChanges() const;
|
||||
|
|
Loading…
Reference in a new issue