Coverage report for ai


src/
File: src/run/listeners/listenConnectNbrResponse.cpp
Date: 2024-06-25 10:57:00
Lines:
0/9
0.0%
Functions:
0/1
0.0%
Branches:
0/37
0.0%

Line Branch Exec Source
1 /*
2 ** EPITECH PROJECT, 2024
3 ** zappy/ai
4 ** File description:
5 ** ListenConnectNbrResponse.cpp
6 */
7
8 #include "../../bots/ABot.hpp"
9
10 void ABot::listenConnectNbrResponse(const std::string &response)
11 {
12 try
13 {
14 _state.slot = std::stoi(response);
15 }
16 catch (std::invalid_argument &e)
17 {
18 PRINT_ERROR("Invalid argument error: " << e.what());
19 }
20 catch (std::out_of_range &e)
21 {
22 PRINT_ERROR("Out of range error: " << e.what());
23 }
24 }
25