Block allocator for lua objects (#640)
- changes lua object allocations that use Luna wrapper from heap allocation to using block allocator
This commit is contained in:
@@ -54,7 +54,7 @@ namespace wi::lua
|
||||
RenderPath3D* comp3D = dynamic_cast<RenderPath3D*>(component->GetActivePath());
|
||||
if (comp3D != nullptr)
|
||||
{
|
||||
Luna<RenderPath3D_BindLua>::push(L, new RenderPath3D_BindLua(comp3D));
|
||||
Luna<RenderPath3D_BindLua>::push(L, comp3D);
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -62,7 +62,7 @@ namespace wi::lua
|
||||
LoadingScreen* compLoad = dynamic_cast<LoadingScreen*>(component->GetActivePath());
|
||||
if (compLoad != nullptr)
|
||||
{
|
||||
Luna<LoadingScreen_BindLua>::push(L, new LoadingScreen_BindLua(compLoad));
|
||||
Luna<LoadingScreen_BindLua>::push(L, compLoad);
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -70,7 +70,7 @@ namespace wi::lua
|
||||
RenderPath2D* comp2D = dynamic_cast<RenderPath2D*>(component->GetActivePath());
|
||||
if (comp2D != nullptr)
|
||||
{
|
||||
Luna<RenderPath2D_BindLua>::push(L, new RenderPath2D_BindLua(comp2D));
|
||||
Luna<RenderPath2D_BindLua>::push(L, comp2D);
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ namespace wi::lua
|
||||
RenderPath* comp = dynamic_cast<RenderPath*>(component->GetActivePath());
|
||||
if (comp != nullptr)
|
||||
{
|
||||
Luna<RenderPath_BindLua>::push(L, new RenderPath_BindLua(comp));
|
||||
Luna<RenderPath_BindLua>::push(L, comp);
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -353,7 +353,7 @@ namespace wi::lua
|
||||
wi::lua::SError(L, "GetCanvas() component is empty!");
|
||||
return 0;
|
||||
}
|
||||
Luna<Canvas_BindLua>::push(L, new Canvas_BindLua(component->canvas));
|
||||
Luna<Canvas_BindLua>::push(L, Canvas_BindLua(component->canvas));
|
||||
return 1;
|
||||
}
|
||||
int Application_BindLua::SetCanvas(lua_State* L)
|
||||
|
||||
Reference in New Issue
Block a user