Comments (3)
Maybe will support reconnect and resend remain message in next version. And this function can easily extend by user, just get disconnect event, and resend message again.
from hisocket.
You can implement this function by yourself, there is a queue of send message, when disconnect to server, you can resend the message in the send queue.
from hisocket.
Hi! @hiramtan
I just found this code and it is very simple and easy to understand! Thank so much for such an awesome plugin!
I need implement reconnect feature(when user drop by a weak signal or switch from wifi to Mobile Data)
Please add to example how to do that!
Thank so much!
In newest version, add a send buffer. When disconnect with server of exception, user can get the remain haven't send bytes from buffer(old version is get message from send queue) and decide to resend it again or just ignore it.
from hisocket.
Related Issues (20)
- i can not recieve disconnected state .is it my problem ? HOT 3
- IndexOutOfRangeException: Index was outside the bounds of the array. HOT 4
- while closing the scene it gives an error on socket.close method HOT 1
- OnDisconnected event has problem HOT 1
- 直接在主线程创建TcpConnect 连接 会阻塞主线程 HOT 5
- 这个socket客户端解决方案,是否支持udp? HOT 4
- 使用 TcpConnection.Connect()没有反应结果,如何捕获连接的异常? HOT 10
- 使用TcpConnection一次性接收16000bit的数据时候报异常 HOT 6
- 请问支持tcp长连接吗? HOT 1
- can i use it with Unity 3d but without extends monobehaviour? like normal c# without Start and Update fucntions HOT 1
- 看起来不错,不知后期是否有融合KCP的打算 HOT 1
- 如果解析失败,数据就被丢弃了。 HOT 1
- When It can not connect to a server, it will throw an exception without catch , this will shut down the appliction. HOT 1
- Problema with expections being thrown HOT 3
- 新版本是否有意愿开发Server端的? HOT 1
- 事件不应在异步方法的回调中触发,因为事件的委托基本上要调用UnityEngine的API,而异步方法的回调不是在Unity主线程中执行的。 HOT 1
- 优化接口
- 编辑器卡死 HOT 5
- StringHexToBytes has problem HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hisocket.