@@ -129,7 +129,7 @@ int main([[maybe_unused]] int argc, [[maybe_unused]] char* argv[])
129
129
130
130
// Handling clients timeout
131
131
serverFlux->_onClientTimeout .addLambda ([](fge::net::ClientSharedPtr client, fge::net::Identity const & id) {
132
- std::cout << " user : " << id._ip . toString (). value_or ( " UNDEFINED " ) << " disconnected (timeout) !" << std::endl;
132
+ std::cout << " user : " << id.toString () << " disconnected (timeout) !" << std::endl;
133
133
});
134
134
135
135
// Handling clients connection
@@ -265,8 +265,8 @@ int main([[maybe_unused]] int argc, [[maybe_unused]] char* argv[])
265
265
transmissionPacket->packet () << true ;
266
266
transmissionPacket->doNotReorder ();
267
267
268
- std::cout << " new user : " << packet->getIdentity ()._ip . toString (). value_or ( " UNDEFINED " )
269
- << " connected ! " << std::endl;
268
+ std::cout << " new user : " << packet->getIdentity ().toString () << " connected ! "
269
+ << std::endl;
270
270
271
271
// Create the new client with the packet identity
272
272
// client = std::make_shared<fge::net::Client>();
@@ -284,6 +284,9 @@ int main([[maybe_unused]] int argc, [[maybe_unused]] char* argv[])
284
284
transmissionPacket->doNotDiscard ();
285
285
mainScene.pack (transmissionPacket->packet (), packet->getIdentity ());
286
286
287
+ std::cout << " transmitting full update with scene update : " << mainScene.getUpdateCount ()
288
+ << std::endl;
289
+
287
290
client->pushPacket (std::move (transmissionPacket));
288
291
}
289
292
@@ -338,8 +341,6 @@ int main([[maybe_unused]] int argc, [[maybe_unused]] char* argv[])
338
341
continue ;
339
342
}
340
343
341
- std::cout << " sending update to : " << it->first ._ip .toString ().value_or (" UNDEFINED" ) << std::endl;
342
-
343
344
auto transmissionPacket = fge::net::CreatePacket ();
344
345
transmissionPacket->setHeaderId (ls::LS_PROTOCOL_S_UPDATE);
345
346
0 commit comments