Showing the changes to libraries/entities/src/EntityScriptingInterface.cpp (1 of 62 files). Show all
Unified · Split
| @@ -1038,6 +1038,15 @@ bool EntityScriptingInterface::isLoaded(const QUuid& id) { · 1037 unmodified lines | |||
| 1038 | return toReturn; | 1038 | return toReturn; |
| 1039 | } | 1039 | } |
| 1040 | 1040 | ||
| 1041 | bool EntityScriptingInterface::isAddedEntity(const QUuid& id) { | ||
| 1042 | bool toReturn = false; | ||
| 1043 | _entityTree->withReadLock([&] { | ||
| 1044 | EntityItemPointer entity = _entityTree->findEntityByEntityItemID(id); | ||
| 1045 | toReturn = (bool)entity; | ||
| 1046 | }); | ||
| 1047 | return toReturn; | ||
| 1048 | } | ||
| 1049 | |||
| 1041 | QSizeF EntityScriptingInterface::textSize(const QUuid& id, const QString& text) { | 1050 | QSizeF EntityScriptingInterface::textSize(const QUuid& id, const QString& text) { |
| 1042 | return EntityTree::textSize(id, text); | 1051 | return EntityTree::textSize(id, text); |
| 1043 | } | 1052 | } |