davey: better enum support

This commit is contained in:
skypjack
2025-05-19 13:38:41 +02:00
parent 6054e93ecc
commit 1b6462a327
2 changed files with 41 additions and 19 deletions

View File

@@ -8,6 +8,13 @@
namespace testbed {
void meta_setup() {
entt::meta_factory<input_listener_component::type>()
.type("command type")
.data<input_listener_component::type::UP>("up")
.data<input_listener_component::type::DOWN>("down")
.data<input_listener_component::type::LEFT>("left")
.data<input_listener_component::type::RIGHT>("right");
entt::meta_factory<input_listener_component>()
.type("input listener")
.data<&input_listener_component::command>("command");