Editor keyboard shortcuts:
Ctrl+S to save the currently selected entity file (iterates to the base parent) Ctrl+N to create a new empty entity under the selection Ctrl+O to import an entity file Del to delete an entity
This commit is contained in:
@@ -10,7 +10,11 @@ bool EntityWrapper::HasComponent(const std::string& componentName)
|
||||
|
||||
EntityWrapper EntityWrapper::Parent()
|
||||
{
|
||||
return EntityWrapper(World, World->GetParent(ID));
|
||||
if (this->World == nullptr || this->ID == EntityID_Invalid) {
|
||||
return EntityWrapper::Invalid;
|
||||
} else {
|
||||
return EntityWrapper(this->World, this->World->GetParent(this->ID));
|
||||
}
|
||||
}
|
||||
|
||||
bool EntityWrapper::Valid()
|
||||
|
||||
Reference in New Issue
Block a user