feat: added conclusion_sent signal to server node

This commit is contained in:
Sara Gerretsen 2025-11-03 12:51:01 +01:00
parent 7c485f1d7d
commit 48cfcd6783
2 changed files with 6 additions and 0 deletions

View file

@ -6,11 +6,16 @@ ServerNode *ServerNode::singleton_instance{ nullptr };
String const ServerNode::sig_clue_revealed{ "clue_revealed" };
String const ServerNode::sig_connection_established{ "connection_established" };
String const ServerNode::sig_connection_lost{ "connection_lost" };
String const ServerNode::sig_conclusion_sent{ "conclusion_sent" };
void ServerNode::_bind_methods() {
ADD_SIGNAL(MethodInfo(sig_clue_revealed, PropertyInfo(Variant::INT, "id")));
ADD_SIGNAL(MethodInfo(sig_connection_established));
ADD_SIGNAL(MethodInfo(sig_connection_lost));
ADD_SIGNAL(MethodInfo(sig_conclusion_sent,
PropertyInfo(Variant::INT, "method", PROPERTY_HINT_ENUM, NetworkData::ClueID_hint()),
PropertyInfo(Variant::INT, "motive", PROPERTY_HINT_ENUM, NetworkData::ClueID_hint()),
PropertyInfo(Variant::INT, "murderer", PROPERTY_HINT_ENUM, NetworkData::ClueID_hint())));
ClassDB::bind_method(D_METHOD("open"), &self_type::open);
ClassDB::bind_method(D_METHOD("close"), &self_type::close);

View file

@ -25,6 +25,7 @@ public:
static String const sig_clue_revealed;
static String const sig_connection_established;
static String const sig_connection_lost;
static String const sig_conclusion_sent;
private:
bool is_connected{ false };