I have some c# code that looks like this :
socket.On(Socket.EVENT_CONNECT, () => { socket.Emit("hi"); socket.On("hi", (data) => { Console.WriteLine(data); socket.Disconnect(); }); });
now, how to convert that to OE ? so far, I have
def var x as Client.Socket no-undo. x = IO:Socket("http://192.168.99.205:49196"). def var y as System.Action. x:on(Socket:EVENT_CONNECT,y). message "here" view-as alert-box.
now, this works, connects to the server and gets to "here".
but how do I convert the c# function to OE and respond to the event ?
TIA
Anyone following this forum has a suggestion or even better a solution to share with Julian?