Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

Tiny C# How Using Network connection and websocket ?

Discussion in 'Project Tiny' started by howonice123, Jun 20, 2019.

  1. howonice123

    howonice123

    Joined:
    Sep 27, 2018
    Posts:
    5
    i cant find web api to connect network and websocket.
    have sample ?
    thanks u help
     
  2. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    87
    I'm not seeing any socket usage in the existing Tiny source. You'd probably have to implement it on your own.
     
  3. VitaFire

    VitaFire

    Joined:
    Jun 10, 2016
    Posts:
    3
    I currently develop a project with websockets but with a old typescript-tiny-Version (14.3).
    But i don`t know how to use them in the c#-version.

    You can just create a Websocket like this:
    Code (JavaScript):
    1. const socket = new WebSocket("ws://serverIP:WS-Port"); //Create websocket.
    2. socket.onmessage = function (message) {
    3.         ReceiveFromServer(message);
    4.     }
     
  4. Vongolar

    Vongolar

    Joined:
    Jan 12, 2018
    Posts:
    3
    I also want to kown how to use http and websocket in C#.