mirror of
https://github.com/lubosz/overte.git
synced 2025-04-16 15:30:11 +02:00
Merge pull request #6937 from ctrlaltdavid/20790
Make entity properties be undefined after entity is unloaded
This commit is contained in:
commit
3e35a5fc2d
2 changed files with 5 additions and 1 deletions
|
@ -1515,7 +1515,6 @@ SelectionDisplay = (function() {
|
|||
}
|
||||
|
||||
that.updateRotationHandles();
|
||||
that.highlightSelectable();
|
||||
|
||||
var rotation, dimensions, position, registrationPoint;
|
||||
|
||||
|
|
|
@ -321,6 +321,11 @@ QScriptValue EntityItemProperties::copyToScriptValue(QScriptEngine* engine, bool
|
|||
QScriptValue properties = engine->newObject();
|
||||
EntityItemProperties defaultEntityProperties;
|
||||
|
||||
if (_created == UNKNOWN_CREATED_TIME) {
|
||||
// No entity properties can have been set so return without setting any default, zero property values.
|
||||
return properties;
|
||||
}
|
||||
|
||||
if (_idSet) {
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE_GETTER_ALWAYS(id, _id.toString());
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue