| 969 | |
| 970 | |
| 971 | void ServerLink::sendCustomData(const std::string& key, const std::string& value) { |
| 972 | if (key.size() + value.size() >= MaxPacketLen) { |
| 973 | return; |
| 974 | } |
| 975 | |
| 976 | char msg[MaxPacketLen]; |
| 977 | void* buf = msg; |
| 978 | buf = nboPackUInt8(buf, uint8_t(getId())); |
| 979 | buf = nboPackStdString(buf, key); |
| 980 | buf = nboPackStdString(buf, value); |
| 981 | send(MsgPlayerData, (uint16_t)((char*)buf - msg), msg); |
| 982 | } |
| 983 | |
| 984 | |
| 985 | bool ServerLink::sendLuaData(PlayerId srcPlayerID, int16_t srcScriptID, |
no test coverage detected