MCPcopy Create free account
hub / github.com/BZFlag-Dev/bzflag / sendMapChangeMessage

Function sendMapChangeMessage

plugins/mapchange/mapchange.cpp:289–307  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

287}
288
289void sendMapChangeMessage(bool end) {
290 std::string message = "Map change!\n";
291 bz_sendTextMessage(BZ_SERVER, BZ_ALLUSERS, message.c_str());
292
293 if (end) {
294 message = "Good bye!\n";
295 }
296 else {
297 message = "Please Rejoin!\n";
298 }
299
300 bz_sendTextMessage(BZ_SERVER, BZ_ALLUSERS, message.c_str());
301
302 if (!end) {
303 bz_sendJoinServer(BZ_ALLUSERS, bz_getPublicAddr().c_str(),
304 bz_getPublicPort(), eNoTeam,
305 bz_getPublicAddr().c_str(), "Map change");
306 }
307}
308
309void nextMap(void) {
310 bool shutdown = false;

Callers 1

nextMapFunction · 0.85

Calls 4

bz_sendTextMessageFunction · 0.85
bz_sendJoinServerFunction · 0.85
bz_getPublicPortFunction · 0.85
c_strMethod · 0.80

Tested by

no test coverage detected