MCPcopy Create free account
hub / github.com/9chu/LuaSTGPlus / DoRender

Method DoRender

LuaSTGPlus/GameObjectPool.cpp:567–589  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

565}
566
567void GameObjectPool::DoRender()LNOEXCEPT
568{
569 GETOBJTABLE; // ot
570
571 GameObject* p = m_pRenderListHeader.pRenderNext;
572 LASSERT(p != nullptr);
573 while (p && p != &m_pRenderListTail)
574 {
575 if (!p->hide) // ֻ��Ⱦ�ɼ�����
576 {
577 // ����id��ȡ�����lua��table���õ�class���õ�renderfunc
578 lua_rawgeti(L, -1, p->id + 1); // ot t(object)
579 lua_rawgeti(L, -1, 1); // ot t(object) t(class)
580 lua_rawgeti(L, -1, LGOBJ_CC_RENDER); // ot t(object) t(class) f(render)
581 lua_pushvalue(L, -3); // ot t(object) t(class) f(render) t(object)
582 lua_call(L, 1, 0); // ot t(object) t(class) ִ����Ⱦ����
583 lua_pop(L, 2); // ot
584 }
585 p = p->pRenderNext;
586 }
587
588 lua_pop(L, 1);
589}
590
591void GameObjectPool::BoundCheck()LNOEXCEPT
592{

Callers 1

ObjRenderMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected