mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2024-11-23 05:57:20 +00:00
use get
This commit is contained in:
parent
e389a619ad
commit
d8e2e92428
@ -786,6 +786,7 @@ void Entity::UpdateXMLDoc(tinyxml2::XMLDocument* doc) {
|
|||||||
|
|
||||||
CppScripts::Script* Entity::GetScript() const {
|
CppScripts::Script* Entity::GetScript() const {
|
||||||
auto* scriptComponent = GetComponent<ScriptComponent>();
|
auto* scriptComponent = GetComponent<ScriptComponent>();
|
||||||
|
if (!scriptComponent) return CppScripts::invalidScript.get();
|
||||||
auto* script = scriptComponent->GetScript();
|
auto* script = scriptComponent->GetScript();
|
||||||
DluAssert(script != nullptr);
|
DluAssert(script != nullptr);
|
||||||
return script;
|
return script;
|
||||||
|
Loading…
Reference in New Issue
Block a user