diff --git a/README.md b/README.md index 38704f9..3d09fe0 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,6 @@ A set of Game Boy Advance (GBA) C++ libraries to interact with the Serial Port. - [🔌](#-LinkGPIO) [LinkGPIO.h](lib/LinkGPIO.h): Use the Link Port however you want to control **any device** (like LEDs, rumble motors, and that kind of stuff)! - [🔗](#-LinkSPI) [LinkSPI.h](lib/LinkSPI.h): Connect with a PC (like a **Raspberry Pi**) or another GBA (with a GBC Link Cable) using this mode. Transfer up to 2Mbit/s! - [📻](#-LinkWireless) [LinkWireless.h](lib/LinkWireless.h): Connect up to 5 consoles with the **Wireless Adapter**! -- [📡](#-LinkWirelessMultiboot) [LinkWirelessMultiboot.h](lib/LinkWirelessMultiboot.h): Send Multiboot software to other GBAs **over the air**! *(click on the emojis for documentation)* diff --git a/examples/LinkWireless_demo/src/main.cpp b/examples/LinkWireless_demo/src/main.cpp index 5b97ddf..d61a45b 100644 --- a/examples/LinkWireless_demo/src/main.cpp +++ b/examples/LinkWireless_demo/src/main.cpp @@ -171,6 +171,12 @@ void messageLoop() { while (true) { u16 keys = ~REG_KEYS & KEY_ANY; + std::string activePlayers = + linkWireless->getState() == LinkWireless::State::SERVING + ? "\n\n" + std::to_string(linkWireless->getPlayerCount()) + + " players" + : ""; + // (5) Send data if (!sending && (keys & KEY_A)) { sending = true; @@ -195,7 +201,7 @@ void messageLoop() { std::string str = "Total: " + std::to_string(receivedData.size()) + "\n"; for (u32& number : receivedData) str += std::to_string(number) + "\n"; - log(str); + log(str + activePlayers); } if (linkWireless->getState() == LinkWireless::State::SERVING) {