Closed wuliao697 closed 1 month ago
These traces suggest the crash is from your plugin than endstone itself. Try to build your plugin with RelWithDebInfo and place the pdb file next to your plugin.
I tried switching RelWithDebInfo, but I have another problem. It won't build after the change. So I tried to build the endstone example plugin. Already deleted the previous build file and had the same problem as this one. Before this I was able to build successfully.
"G:\CLion 2023.3.3\bin\cmake\win\x64\bin\cmake.exe" --build C:\Users\...\cpp-example-plugin-main\cmake-build-release --target cpp_example -j 6
[1/3] Linking CXX static library _deps\fmt-build\fmt.lib
[2/3] Building CXX object CMakeFiles\cpp_example.dir\src\example_plugin.cpp.obj
FAILED: CMakeFiles/cpp_example.dir/src/example_plugin.cpp.obj
C:\PROGRA~1\MIB055~1\2022\COMMUN~1\VC\Tools\MSVC\1438~1.331\bin\Hostx64\x64\cl.exe /nologo /TP -Dcpp_example_EXPORTS -IC:\Users\admin\...\cpp-example-plugin-main\include -IC:\Users\admin\...\cpp-example-plugin-main\cmake-build-release\_deps\endstone-src\include -IC:\Users\admin\...\cpp-example-plugin-main\cmake-build-release\_deps\fmt-src\include /DWIN32 /D_WINDOWS /GR /EHsc /D_ITERATOR_DEBUG_LEVEL=0 /O2 /Ob2 /DNDEBUG -std:c++17 -MD /showIncludes /FoCMakeFiles\cpp_example.dir\src\example_plugin.cpp.obj /FdCMakeFiles\cpp_example.dir\ /FS -c C:\...\cpp-example-plugin-main\src\example_plugin.cpp
C:\...\cpp-example-plugin-main\cmake-build-release\_deps\endstone-src\include\endstone/util/result.h(17): fatal error C1083: 无法打开包括文件: “nonstd/expected.hpp”: No such file or directory
ninja: build stopped: subcommand failed.
I apologize for my cheap shot on these.
It seems likely that the issue is related to the version specified in the CMakeLists.txt
. Please try changing the GIT_TAG
from main
to the release version you are using (e.g., v0.5.4
or v0.5.4.1
). If the version isn’t fixed, the build will pull the latest commit from upstream. This explains the crashes in your case due to ABI breaks, as we are frequently making changes to the C++ API.
Problem solved, really appreciate it. I wish this community project will be better and better.
Describe the bug I'm trying to get the name of the player on the playerjoin event. Server crashes when players enter the game. I have no problem getting the player's uuid. This issue should have been a problem since version 0.5.1.
To Reproduce
Expected behavior