Added Screen space reflections and Editor UI refactoring

This commit is contained in:
antopilo
2022-01-31 13:54:58 -05:00
parent e216686272
commit b273a2fb8a
78 changed files with 2454 additions and 946 deletions

View File

@@ -13,22 +13,17 @@ namespace Nuake {
{
ScriptingEngine::Init();
auto entities = m_Scene->m_Registry.view<WrenScriptComponent>();
for (auto e : entities)
auto& entities = m_Scene->m_Registry.view<WrenScriptComponent>();
for (auto& e : entities)
{
WrenScriptComponent& wren = entities.get<WrenScriptComponent>(e);
if (wren.Script != "" && wren.Class != "")
{
wren.mWrenScript = CreateRef<WrenScript>(wren.Script, wren.Class, true);
if (!wren.mWrenScript->CompiledSuccesfully)
return false;
}
wren.mWrenScript->Build(wren.mModule, true);
if (!wren.mWrenScript->HasCompiledSuccesfully())
return false;
if (wren.mWrenScript != nullptr)
{
wren.mWrenScript->SetScriptableEntityID((int)e);
wren.mWrenScript->CallInit();
}
wren.mWrenScript->SetScriptableEntityID((int)e);
wren.mWrenScript->CallInit();
}
return true;