onMissCustomCmdMsg property
final
Loss of Custom Message
When you use sendCustomCmdMsg
to send a custom UDP message, even if
you enable reliable transfer (by setting reliable
to true
), there is
still a chance of message loss. Reliable transfer only helps maintain a
low probability of message loss, which meets the reliability requirements
in most cases.
If the sender sets reliable
to true
, the SDK will use this callback
to notify the recipient of the number of custom messages lost during a
specified time period (usually 5s) in the past.
- Parameters:
- cmdID(int):
- Command ID.
- errCode(int):
- Error code.
- missed(int):
- Number of lost messages.
- userId(String):
- User ID.
- cmdID(int):
Note The recipient receives this callback only if the sender sets
reliable
totrue
.
Implementation
final void Function(String userId, int cmdId, int errCode, int missed)? onMissCustomCmdMsg;