diff options
author | rubidium42 <rubidium@openttd.org> | 2021-05-02 08:43:11 +0200 |
---|---|---|
committer | rubidium42 <rubidium42@users.noreply.github.com> | 2021-05-03 17:56:05 +0200 |
commit | 7bcc472f73c774163285f71c235852ba0911e88e (patch) | |
tree | d0ffec49379c66766cb84b1b1e769a878617894f /src/network/core/packet.h | |
parent | ba409e8c4502cc435d0d3f4bec7ba5f5fe28b658 (diff) | |
download | openttd-7bcc472f73c774163285f71c235852ba0911e88e.tar.xz |
Add: [Network] Reading std::string from a packet
Diffstat (limited to 'src/network/core/packet.h')
-rw-r--r-- | src/network/core/packet.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/network/core/packet.h b/src/network/core/packet.h index 0f58d3be8..21a88e3ea 100644 --- a/src/network/core/packet.h +++ b/src/network/core/packet.h @@ -88,6 +88,7 @@ public: uint32 Recv_uint32(); uint64 Recv_uint64(); void Recv_string(char *buffer, size_t size, StringValidationSettings settings = SVS_REPLACE_WITH_QUESTION_MARK); + std::string Recv_string(size_t length, StringValidationSettings settings = SVS_REPLACE_WITH_QUESTION_MARK); size_t RemainingBytesToTransfer() const; |