Coverage report for ai


src/
File: src/run/listeners/broadcast/ListenBroadcastResponse.cpp
Date: 2024-06-25 10:57:00
Lines:
0/10
0.0%
Functions:
0/1
0.0%
Branches:
0/14
0.0%

Line Branch Exec Source
1 /*
2 ** EPITECH PROJECT, 2024
3 ** zappy/ai
4 ** File description:
5 ** ListenBroadcastResponse.cpp
6 */
7
8 #include "../../../bots/ABot.hpp"
9
10 #include <iostream>
11 #include <string>
12 #include <sstream>
13
14 void ABot::listenBroadcastResponse()
15 {
16 // Listeners Broadcast
17 if (_allyMessage.content.find("group") != std::string::npos)
18 {
19 listenGroupBroadcast(_allyMessage.content);
20 }
21 else if (_allyMessage.content.find("joined") != std::string::npos && _state.metadata["ask_for_group"] == "true")
22 {
23 listenGroupJoinedBroadcast(_allyMessage.content);
24 }
25 else if (_allyMessage.content.find("meeting") != std::string::npos)
26 {
27 listenMeetingDoneBroadcast(_allyMessage.content);
28 }
29 else if (_allyMessage.content.find("warns"))
30 listenWarnsBroadcast(_allyMessage.content);
31 }
32