How to encode a web browser based multiplayer game?

If I wanted to encode a board game, I could pull out the XNA code and UDP sockets and make a decent multiplayer game. It would be very clear to me how to encode the game that I wanted.

But if I wanted to encode a browser-based multiplayer game, how would I do it? You cannot use XNA .... I was looking for some questions and I see PHP and ASP.NET, Silverlight and Flash and Java as alternative languages ​​... I really don’t understand how this works, I mean that For a board game, you open a UDP socket and receive clients and transfer data, updating the status of players, drawing results using XNA. But in the browser, how do you open a socket and stuff? How this concept works, communicating with people in real time through a web browser. Any direction? I am familiar with C # and semi-familiar with Java. Never made Flash, ASP.NET or Silverlight.

+3
source share
6

. . , .

1 34,29. 35,30. - AJAX. , - . - , .

Google Microsoft Word. , - , - HTTP-.

+4

, , Silverlight Flash, Java. , - , UDP/.

#, Silverlight, -, .

+2

, . Flash , , php ajax, Java. , .

0

, . -, , . , , - . , .

, .

UDP/... - , - AJAX FLASH ( , Async, ).

, keyboard -> program -> monitor keyboard -> browser-scripts -> AJAX request -> server-scripts -> monitor.

0

# Java, Unity3D ( ) SmartfoxServer .

Unity3D - , , . , Javascript #. SmartfoxServer - , Java, API .

, 2D/3D.

0

You might want to take a look at web sockets in HTML5. Depending on which game you want to make, pure HTML5 using Canvas and some javascript library like jQuery may be exactly what you are looking for.

0
source

Source: https://habr.com/ru/post/1752517/


All Articles