#include "../ui/ComponentRegistration.hpp"
#include "../ui/StartupMenuEditor.hpp"
#include "StartupMenu.hpp"

REGISTER_COMPONENT_GROUP("Startup Menu", "Game", StartupMenuComponent,
			 StartupMenuEditor)
{
	registry.registerComponent<StartupMenuComponent>(
		StartupMenuComponent_name, StartupMenuComponent_group,
		std::make_unique<StartupMenuEditor>(),
		// Adder
		[](flecs::entity e) {
			if (!e.has<StartupMenuComponent>()) {
				e.set<StartupMenuComponent>({});
			}
		},
		// Remover
		[](flecs::entity e) {
			if (e.has<StartupMenuComponent>()) {
				e.remove<StartupMenuComponent>();
			}
		});
}
