When the start button is pressed, switch to a "connecting" state. This
triggers the spawning of the "connecting" UI message and the connection
startup.
When the connection task finishes, `fn handle_tasks()` collects it and
pushes the CommandQueue into the main world just as before. In addition,
it will change to the "playing" state, which triggers the despawning of
the UI notice.
There is no meaningful connection-error handling path. A failed
connection will print a warning to stdout, and that is all.
There is still no transmitter at all, nor is the receiver hooked up to
one of the paddles.
This is mostly a copy of ambiso/bevy_websocket_example:
https://github.com/ambiso/bevy_websocket_example/tree/main
It demonstrates how to hold and use a (Tungstenite) WebSocket in a Bevy
app. I've altered it slightly (and skipped impl'ing the send function)
to fit my own chatroom dummy target.
This is completely useless as a chatroom app, but it's not supposed to
be one. Now I can move on to building the actual Pong game!
I'm planning to use WebSockets for game networking because it can be
used both on native and web environments.
I need some time and tools to figure out how to make Bevy hold and use a
WebSocket. I've taken the Axum WS text chat for use as a dummy activity
so I can build out a Bevy app which implements the text chat behavior.