Conversation
PuppetMasterHex
commented
Apr 4, 2026
- Added protobuf save feature and made it the new default
- Saving -> ProtoSave::SaveCharProtobuf
- Loading -> ProtoSave::LoadCharProtobuf
- Protobuf can export to JSON -> ProtoSave::SaveCharJSON
- Compatible with old save files
- First protobuf tries to parse the data
- If it fails there is a fallback to the old save loader
- Added dockerfile for easy compiling and testing
- Can volume mount hlds in the container and run the server there
- docker/run_server.sh copies the ms.so and config files before starting hlds for faster testing
- Minor improvements
- Compile multithreaded with -j8 on linux
- Made msstring::c_str() const
|
Sorry for the delay I'll get to looking at this soon, been busy these last few days. |
SaintWish
left a comment
There was a problem hiding this comment.
Seems windows fails to compile because of the find_package for protobuf (https://github.com/MSRevive/MasterSwordRebirth/actions/runs/23979449975/job/70516350440?pr=370)
There was a problem hiding this comment.
I'm not sure why the compiler and compile flags are set here when they were already set here https://github.com/MSRevive/MasterSwordRebirth/blob/dev/CMakeLists.txt
There was a problem hiding this comment.
Not sure why the flags in the CMakeLists.txt are ignored, the block is executed I tested that.
When the entry in the LinuxToolchain.cmake is removed, there are linker errors because cmake doesn't link the 32bit libprotobuf:
protosave.cpp:(.text+0x2d2b): undefined reference to `google::protobuf::RepeatedPtrFieldstd::string::Add()'
There was a problem hiding this comment.
Try moving find_package(Protobuf REQUIRED) to the server and client CMakeLists, that might fix that?
There was a problem hiding this comment.
I've tested some combinations and -D_GLIBCXX_USE_CXX11_ABI=0 causes the linking of libprotobuf to fail.
@tschumann you've added this in commit 8e05d36, do you remember where this was needed back then?
Building and running in the container works fine without that flag.
|
Still a few todo debugs as well.
Also, what are the URLs in the .cfg files?
…On Thu, 9 Apr 2026 at 13:23, Saint Wish ***@***.***> wrote:
***@***.**** requested changes on this pull request.
Seems windows fails to compile because of the find_package for protobuf (
https://github.com/MSRevive/MasterSwordRebirth/actions/
runs/23979449975/job/70516350440?pr=370)
------------------------------
On src/game/server/save/protosave.h
<#370 (comment)>
:
That license at the top would restrict anyone but you from ever modifying
this code, and is incompatible with the HL SDK and GPL3.0 license.
------------------------------
On src/game/server/save/protosave.cpp
<#370 (comment)>
:
That license at the top would restrict anyone but you from ever modifying
this code, and is incompatible with the HL SDK and GPL3.0 license.
Instead of using the C++ std filesystem please use the engine's filesystem
https://github.com/MSRevive/MasterSwordRebirth/blob/dev/
src/game/shared/filesystem_shared.h
------------------------------
On cmake/LinuxToolchain.cmake
<#370 (comment)>
:
I'm not sure why the compiler and compile flags are set here when they
were already set here https://github.com/MSRevive/
MasterSwordRebirth/blob/dev/CMakeLists.txt
—
Reply to this email directly, view it on GitHub
<#370 (review)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AA34IYSAF2FTUJEB5HU3GTT4U4JU5AVCNFSM6AAAAACXMUMW2KVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHM2DANZZGQ3TCNZTHA>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Good catch! |
1dfa5b8 to
df8479f
Compare
I have removed the debug comments, only kept the The .cfg files (and these URLs) come from the default .cfgs shipped with MSR, I have replaced the URLs with example.org |
The WindowsToolchain.cmake includes vcpkg but I cannot find the file included there. I think cpm would also work. |
df8479f to
d7540df
Compare
|
The preferred way for now is to just add them manually to thirdpart either just the code or if it needs to be compiled then the compiled form, like for example the libcurl. I tried using vcpkg once but had nothing but problems with it and git dependencies.
|
At some point we want to get rid of mslist and just use the appropriate standard lib option same for msstring. |
Signed-off-by: Genesis <10389486+PuppetMasterHex@users.noreply.github.com>
Signed-off-by: Genesis <10389486+PuppetMasterHex@users.noreply.github.com>
With the dockerfile it is not necessary anymore Signed-off-by: Genesis <10389486+PuppetMasterHex@users.noreply.github.com>
…onfigs Signed-off-by: Genesis <10389486+PuppetMasterHex@users.noreply.github.com>
The data is not modified in the function so it should be const Signed-off-by: Genesis <10389486+PuppetMasterHex@users.noreply.github.com>
d7540df to
adb4bff
Compare
I have added cmake/protobuf.cmake that uses CPM to fetch and build protobuf for windows, but I cannot test if the target_link_libaries works for |
Also committed the protoc generated files since BPM doesnt support a two stage build to build protoc before running 'cmake -B' Signed-off-by: Genesis <10389486+PuppetMasterHex@users.noreply.github.com>
adb4bff to
85db73d
Compare
|
If it fails to build again on windows I can just merge it and work on it when I have time |