1

I'm aware it's not possible to establish UDP connections with pure javascript. Even the most popular webapi for establishing connections, Websocket, use TCP and it's not possible to change it.

However i've came across WebRTC and it does use UDP underneath.

Is it possible to use the same code WebRTC is using underneath to establish custom UDP connections?

nluizsoliveira
  • 355
  • 1
  • 9
  • 1
    Not sure on why to use UDP as it works more like a broadcasting protocol, where TCP is p2p. Some more on [this post](https://stackoverflow.com/questions/29532157/how-to-talk-to-udp-sockets-with-html5) – Flewz Dec 06 '22 at 13:55
  • 1
    Take a look at https://github.com/RedpointGames/netcode.io-browser – Dorin Botan Dec 06 '22 at 13:56

0 Answers0