#include #include using namespace Ubpa; using namespace Ubpa::UECS; using namespace std; struct P {}; struct V {}; struct A {}; struct VP_System { static void OnUpdate(Schedule& schedule) { schedule.RegisterEntityJob([](const V*, P*) {cout << "VP" << endl; }, "VP"); } }; struct AVP_System { static void OnUpdate(Schedule& schedule) { schedule.RegisterEntityJob([](const A*, V*, P*) {cout << "AVP" << endl; }, "AVP"); schedule.AddNone("VP", TypeID_of); } }; int main() { World w; w.entityMngr.cmptTraits.Register(); w.systemMngr.RegisterAndActivate(); w.entityMngr.Create(Ubpa::TypeIDs_of< V, P>); w.entityMngr.Create(Ubpa::TypeIDs_of); w.Update(); cout << w.DumpUpdateJobGraph() << endl; return 0; }