From 3564f4d653fb1f60880ad70510fb90f482c6077e Mon Sep 17 00:00:00 2001 From: diamante0018 Date: Sun, 16 Nov 2025 21:30:39 +0100 Subject: [PATCH] chore: update --- deps/GSL | 2 +- deps/gsc-tool | 2 +- deps/libtomcrypt | 2 +- deps/minhook | 2 +- .../game/demonware/services/bdStorage.cpp | 2 +- src/client/resources/dw/motd-english.txt | 2 +- src/common/utils/string.hpp | 26 +++++++++---------- 7 files changed, 19 insertions(+), 19 deletions(-) diff --git a/deps/GSL b/deps/GSL index 7e0943d..543d0dd 160000 --- a/deps/GSL +++ b/deps/GSL @@ -1 +1 @@ -Subproject commit 7e0943d20d3082b4f350a7e0c3088d2388e934de +Subproject commit 543d0dd3fe966ddf20e884b44e5fdbf12cb43784 diff --git a/deps/gsc-tool b/deps/gsc-tool index c508e5b..c9bd8e5 160000 --- a/deps/gsc-tool +++ b/deps/gsc-tool @@ -1 +1 @@ -Subproject commit c508e5b10f5ecef9313ef49b0ec6b8ebf52e182f +Subproject commit c9bd8e5c6aec6ec77f7089208892871c9eb8597a diff --git a/deps/libtomcrypt b/deps/libtomcrypt index d448df1..c421e57 160000 --- a/deps/libtomcrypt +++ b/deps/libtomcrypt @@ -1 +1 @@ -Subproject commit d448df1938e8988bcdb0eed6591387e82b26874b +Subproject commit c421e570c6ba6c2c0999f99386314f38948af8e0 diff --git a/deps/minhook b/deps/minhook index 565968b..1e9ad1e 160000 --- a/deps/minhook +++ b/deps/minhook @@ -1 +1 @@ -Subproject commit 565968b28583221751cc2810e09ea621745fc3a3 +Subproject commit 1e9ad1eb42db11bfcb65461f687c656612d1b555 diff --git a/src/client/game/demonware/services/bdStorage.cpp b/src/client/game/demonware/services/bdStorage.cpp index 1ba8555..0e859ee 100644 --- a/src/client/game/demonware/services/bdStorage.cpp +++ b/src/client/game/demonware/services/bdStorage.cpp @@ -15,7 +15,7 @@ namespace demonware { std::string get_motd_text() { - return "This is not a copy & pasted client"; + return "Did you know aiming down sights increases accuracy? Online Interactions Not Rated by the ESRB."; } } diff --git a/src/client/resources/dw/motd-english.txt b/src/client/resources/dw/motd-english.txt index c567a76..dd6f1ce 100644 --- a/src/client/resources/dw/motd-english.txt +++ b/src/client/resources/dw/motd-english.txt @@ -1 +1 @@ -Welcome to s1-mod. This is not a copy & pasted project. \ No newline at end of file +Welcome to s1-mod. Did you know aiming down sights increases accuracy? Online Interactions Not Rated by the ESRB. \ No newline at end of file diff --git a/src/common/utils/string.hpp b/src/common/utils/string.hpp index 2757d2e..e9e5860 100644 --- a/src/common/utils/string.hpp +++ b/src/common/utils/string.hpp @@ -22,54 +22,54 @@ namespace utils::string ++this->current_buffer_ %= ARRAY_COUNT(this->string_pool_); auto entry = &this->string_pool_[this->current_buffer_]; - if (!entry->size || !entry->buffer) + if (!entry->size_ || !entry->buffer_) { throw std::runtime_error("String pool not initialized"); } while (true) { - const int res = vsnprintf_s(entry->buffer, entry->size, _TRUNCATE, format, ap); + const auto res = vsnprintf_s(entry->buffer_, entry->size_, _TRUNCATE, format, ap); if (res > 0) break; // Success if (res == 0) return nullptr; // Error entry->double_size(); } - return entry->buffer; + return entry->buffer_; } private: class entry final { public: - explicit entry(const size_t _size = MinBufferSize) : size(_size), buffer(nullptr) + explicit entry(const size_t size = MinBufferSize) : size_(size), buffer_(nullptr) { - if (this->size < MinBufferSize) this->size = MinBufferSize; + if (this->size_ < MinBufferSize) this->size_ = MinBufferSize; this->allocate(); } ~entry() { - if (this->buffer) memory::get_allocator()->free(this->buffer); - this->size = 0; - this->buffer = nullptr; + if (this->buffer_) memory::get_allocator()->free(this->buffer_); + this->size_ = 0; + this->buffer_ = nullptr; } void allocate() { - if (this->buffer) memory::get_allocator()->free(this->buffer); - this->buffer = memory::get_allocator()->allocate_array(this->size + 1); + if (this->buffer_) memory::get_allocator()->free(this->buffer_); + this->buffer_ = memory::get_allocator()->allocate_array(this->size_ + 1); } void double_size() { - this->size *= 2; + this->size_ *= 2; this->allocate(); } - size_t size; - char* buffer; + size_t size_; + char* buffer_; }; size_t current_buffer_;