private void EmitPacket(Packet packet) { try { ws.Send(Encoder.Encode(packet)); } catch (SocketIOException ex) { Debug.LogError(ex.Message); } }
private void EmitPacket(Packet packet) { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif try { ws.Send(encoder.Encode(packet)); } catch (SocketIOException ex) { Debug.Log(ex.ToString()); } }
public void EmitPacket(Packet packet) { Info("[SocketIO]EmitPacket " + packet); try { ws.Send(encoder.Encode(packet)); } catch (SocketIOException ex) { Error(ex.ToString()); } }
private void EmitPacket(Packet packet) { try { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif ws.Send(Encoder.Encode(packet)); } catch (SocketIOException ex) { Debug.LogError(ex.Message); } }
private void EmitPacket(Packet packet) { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif try { ws.Send(encoder.Encode(packet)); #pragma warning disable CS0168 // Variable is declared but never used } catch (SocketIOException ex) { #pragma warning restore CS0168 // Variable is declared but never used #if SOCKET_IO_DEBUG debugMethod.Invoke(ex.ToString()); #endif } }
private void EmitPacket(Packet packet) { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif try { ws.Send(encoder.Encode(packet)); } catch (SocketIOException ex) { #if UNITY_EDITOR Debug.LogError(ex.Message); #endif #if SOCKET_IO_DEBUG debugMethod.Invoke(ex.ToString()); #endif } }
private void EmitPacket(Packet packet) { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif if (myDebugLog != null && packet != null) { myDebugLog.Invoke("Send Emit : " + packet.json); } try { ws.Send(encoder.Encode(packet)); } catch (SocketIOException ex) { #if SOCKET_IO_DEBUG debugMethod.Invoke(ex.ToString()); #endif } }
private void EmitPacket(Packet packet) { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif #pragma warning disable 0168 try { ws.Send(encoder.Encode(packet)); } catch (SocketIOException ex) { #if SOCKET_IO_DEBUG debugMethod.Invoke(ex.ToString()); #endif } #pragma warning restore 0168 }
private void EmitPacket(Packet packet) { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif try { // var sw = new System.Diagnostics.Stopwatch (); // sw.Start (); ws.Send(encoder.Encode(packet)); // sw.Stop (); // UnityEngine.Debug.Log ("send took " + sw.Elapsed.TotalSeconds + " seconds"); } catch (SocketIOException ex) { #if SOCKET_IO_DEBUG debugMethod.Invoke(ex.ToString()); #endif } }
private void EmitPacket(Packet packet) { #if SOCKET_IO_DEBUG debugMethod.Invoke("[SocketIO] " + packet); #endif try { ws.Send(encoder.Encode(packet)); } // @fix: This fix prevents from warning errors about the unused "ex" variable if the SOCKET_IO_DEBUG define is not declared #if SOCKET_IO_DEBUG catch (SocketIOException ex) { debugMethod.Invoke(ex.ToString()); } #else catch (SocketIOException) { } #endif }