diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index ea9c0f38d07..2b23578f27b 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -11,7 +11,9 @@ "remoteUser": "xiadmin", "remoteEnv": { "LOCAL_WORKSPACE_FOLDER": "${localWorkspaceFolder}" }, "features": { - "ghcr.io/devcontainers/features/docker-outside-of-docker:1": {} + "ghcr.io/devcontainers/features/docker-outside-of-docker:1": { + "moby": false + } }, "customizations": { "vscode": { diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 37775e6874c..9a537453bef 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -15,9 +15,9 @@ jobs: name: Clang Tidy uses: ./.github/workflows/runner_build.yml with: - runner: ubuntu-24.04 + runner: ubuntu-26.04 compiler: clang - compiler_version: 20 + compiler_version: 22 build_type: Debug tracy: false build_modules: false @@ -64,9 +64,9 @@ jobs: upload_artifact: false clang_tidy: false - build_type: Debug - runner: ubuntu-24.04 + runner: ubuntu-26.04 compiler: gcc - compiler_version: 14 + compiler_version: 15 tracy: false build_modules: false save_cache: true @@ -93,8 +93,8 @@ jobs: - build_type: Release os: ubuntu compiler: gcc - compiler_version: 14 - clang_format_version: 20 + compiler_version: 15 + clang_format_version: 22 tracy: false build_modules: false save_cache: false @@ -110,8 +110,8 @@ jobs: - build_type: Release os: alpine compiler: clang - compiler_version: 20 - clang_format_version: 20 + compiler_version: 22 + clang_format_version: 22 tracy: false build_modules: false save_cache: false diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index ef8ce00c149..7b4eea574ed 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -9,14 +9,15 @@ on: jobs: Publish_Changelog: name: Generate and Publish Changelog - runs-on: ubuntu-24.04 + runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 - - uses: fregante/setup-git-user@v1 + - uses: actions/checkout@v6 + - run: git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" + - run: git config --global user.name "github-actions[bot]" - name: Install dependencies run: | sudo apt-get update - sudo apt-get install -y python3.7 + sudo apt-get install -y python3 pip3 install requests - name: Generate changelog run: | diff --git a/.github/workflows/check_template.yml b/.github/workflows/check_template.yml index 6ed442959aa..2ffffb43344 100644 --- a/.github/workflows/check_template.yml +++ b/.github/workflows/check_template.yml @@ -13,7 +13,7 @@ jobs: permissions: write-all steps: - name: Comment on unchecked boxes in template - uses: actions/github-script@v7 + uses: actions/github-script@v9 with: script: | function count_instances(string, word) diff --git a/.github/workflows/codeql_analysis.yml b/.github/workflows/codeql_analysis.yml index e5c00168af9..22f79232503 100644 --- a/.github/workflows/codeql_analysis.yml +++ b/.github/workflows/codeql_analysis.yml @@ -36,7 +36,7 @@ jobs: steps: - name: Checkout repository - uses: actions/checkout@v3 + uses: actions/checkout@v6 - name: Install Dependencies run: | @@ -45,7 +45,7 @@ jobs: # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v2 + uses: github/codeql-action/init@v4 with: trap-caching: false languages: ${{ matrix.language }} @@ -57,7 +57,7 @@ jobs: # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). # If this step fails, then you should remove it and run the build manually (see below) # - name: Autobuild - # uses: github/codeql-action/autobuild@v2 + # uses: github/codeql-action/autobuild@v4 # ℹ️ Command-line programs to run using the OS shell. # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun @@ -73,7 +73,7 @@ jobs: cmake --build build -j4 - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v2 + uses: github/codeql-action/analyze@v4 with: # https://josh-ops.com/posts/github-codeql-ignore-files/ upload: false # disable the upload here - we will upload in a different action @@ -89,6 +89,6 @@ jobs: output: sarif-results/${{ matrix.language }}.sarif - name: Upload SARIF - uses: github/codeql-action/upload-sarif@v2 + uses: github/codeql-action/upload-sarif@v4 with: sarif_file: sarif-results/${{ matrix.language }}.sarif diff --git a/.github/workflows/discussion_keyword_comment.yml b/.github/workflows/discussion_keyword_comment.yml index 78ff1c085e7..0bb6abd2b46 100644 --- a/.github/workflows/discussion_keyword_comment.yml +++ b/.github/workflows/discussion_keyword_comment.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Comment on keywords in Discussion - uses: actions/github-script@v6 + uses: actions/github-script@v9 with: script: | // Define the keywords to check (all lower-case for case-insensitive matching) diff --git a/.github/workflows/docker_build.yml b/.github/workflows/docker_build.yml index e05155b41a5..096098998af 100644 --- a/.github/workflows/docker_build.yml +++ b/.github/workflows/docker_build.yml @@ -67,13 +67,13 @@ jobs: echo "REPO_OWNER=${GITHUB_REPOSITORY_OWNER,,}" >>${GITHUB_ENV} echo "REPO=${GITHUB_REPOSITORY,,}" >>${GITHUB_ENV} - - uses: docker/login-action@v3 + - uses: docker/login-action@v4 with: registry: ghcr.io username: ${{ github.repository_owner }} password: ${{ secrets.GITHUB_TOKEN }} - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 1 @@ -88,12 +88,12 @@ jobs: f.write("renamer\n") EOF - - uses: docker/setup-buildx-action@v3 + - uses: docker/setup-buildx-action@v4 id: setup_buildx - name: Restore build cache if: ${{ !inputs.save_cache }} - uses: actions/cache/restore@v4 + uses: actions/cache/restore@v5 env: cmake_hash: ${{ hashFiles('**/CMakeLists.txt', '**/*.cmake') }} source_hash: ${{ hashFiles('src/**/*', 'ext/**/*') }} @@ -108,7 +108,7 @@ jobs: - name: Cache build id: cache_build if: ${{ inputs.save_cache }} - uses: actions/cache@v4 + uses: actions/cache@v5 env: cmake_hash: ${{ hashFiles('**/CMakeLists.txt', '**/*.cmake') }} source_hash: ${{ hashFiles('src/**/*', 'ext/**/*') }} @@ -121,7 +121,7 @@ jobs: ${{ format('buildcache-docker-{0}-{1}{2}-{3}-{4}-', inputs.os, inputs.compiler, inputs.compiler_version, inputs.build_type, env.cmake_hash) }} - name: Inject cache into container - uses: reproducible-containers/buildkit-cache-dance@v3.2.0 + uses: reproducible-containers/buildkit-cache-dance@v3.4.0 with: builder: ${{ steps.setup_buildx.outputs.name }} cache-map: | @@ -145,7 +145,7 @@ jobs: - name: Docker meta id: docker-meta - uses: docker/metadata-action@v5 + uses: docker/metadata-action@v6 with: images: ghcr.io/${{ env.REPO }} tags: | @@ -161,7 +161,7 @@ jobs: - name: Build devtools image if: ${{ inputs.publish && vars.PUBLISH_DOCKER != '' }} - uses: docker/build-push-action@v6 + uses: docker/build-push-action@v7 with: context: . file: ${{ format('./docker/{0}.Dockerfile', inputs.os) }} @@ -173,7 +173,7 @@ jobs: tags: ${{ format('ghcr.io/{0}/devtools:{1}', env.REPO_OWNER, inputs.os) }} - name: Docker build and push - uses: docker/build-push-action@v6 + uses: docker/build-push-action@v7 with: context: . file: ${{ format('./docker/{0}.Dockerfile', inputs.os) }} @@ -194,7 +194,7 @@ jobs: - name: Archive image if: ${{ inputs.upload_artifact || (inputs.publish && vars.PUBLISH_DOCKER == '') }} - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@v7 with: name: ${{ format('LSB_{0}_image_{1}', inputs.os, github.sha) }} path: ${{ format('{0}/LSB_{1}_image_{2}.tar', runner.temp, inputs.os, github.sha) }} diff --git a/.github/workflows/docker_test.yml b/.github/workflows/docker_test.yml index 4d07215ef0e..c2d45d41e28 100644 --- a/.github/workflows/docker_test.yml +++ b/.github/workflows/docker_test.yml @@ -57,21 +57,21 @@ jobs: echo "REPO_OWNER=${GITHUB_REPOSITORY_OWNER,,}" >>${GITHUB_ENV} echo "REPO=${GITHUB_REPOSITORY,,}" >>${GITHUB_ENV} - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 1 submodules: recursive # For navmeshes - name: Download artifact if: ${{ github.event_name == 'pull_request' }} - uses: actions/download-artifact@v4 + uses: actions/download-artifact@v8 with: name: ${{ env.artifact_name }} path: ${{ runner.temp }} - name: Download previous artifact if: ${{ (github.event_name == 'workflow_run' || github.event_name == 'workflow_dispatch') && vars.PUBLISH_DOCKER == ''}} - uses: dawidd6/action-download-artifact@v3 + uses: dawidd6/action-download-artifact@v21 with: run_id: ${{ github.event.workflow_run.id }} name: ${{ env.artifact_name }} diff --git a/.github/workflows/pr_checks.yml b/.github/workflows/pr_checks.yml index 38c4ce95531..a2ed979fd24 100644 --- a/.github/workflows/pr_checks.yml +++ b/.github/workflows/pr_checks.yml @@ -46,7 +46,7 @@ jobs: run: tr -d '\r' < sanity_checks_summary.md >> $GITHUB_STEP_SUMMARY - name: Upload changed files as artifact - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@v7 with: name: changed-files path: changed-files.txt @@ -63,7 +63,7 @@ jobs: shell: bash steps: - name: Download Changed Files - uses: actions/download-artifact@v4 + uses: actions/download-artifact@v8 with: name: changed-files @@ -142,7 +142,7 @@ jobs: shell: bash steps: - name: Download Changed Files - uses: actions/download-artifact@v4 + uses: actions/download-artifact@v8 with: name: changed-files @@ -188,7 +188,7 @@ jobs: shell: bash steps: - name: Download Changed Files - uses: actions/download-artifact@v4 + uses: actions/download-artifact@v8 with: name: changed-files @@ -242,9 +242,9 @@ jobs: name: Clang Tidy uses: ./.github/workflows/runner_build.yml with: - runner: ubuntu-24.04 + runner: ubuntu-26.04 compiler: clang - compiler_version: 20 + compiler_version: 22 build_type: Debug build_modules: false tracy: false @@ -268,9 +268,9 @@ jobs: compiler: appleClang build_modules: false - build_type: Debug - runner: ubuntu-24.04 + runner: ubuntu-26.04 compiler: gcc - compiler_version: 14 + compiler_version: 15 build_modules: false uses: ./.github/workflows/runner_build.yml with: @@ -299,7 +299,7 @@ jobs: multi_process: false xi_test: false startup_checks: true - - runner: ubuntu-24.04 + - runner: ubuntu-26.04 test_modules: false multi_process: false xi_test: true diff --git a/.github/workflows/pr_labels.yml b/.github/workflows/pr_labels.yml index 6268aa0c17b..f467a9650b7 100644 --- a/.github/workflows/pr_labels.yml +++ b/.github/workflows/pr_labels.yml @@ -16,7 +16,7 @@ jobs: permissions: write-all steps: - name: Check for blocking labels - uses: actions/github-script@v7 + uses: actions/github-script@v9 with: script: | const response = await github.rest.issues.listLabelsOnIssue({ diff --git a/.github/workflows/publish_meshes.yml b/.github/workflows/publish_meshes.yml index 906dcecdbf8..81f45d4f105 100644 --- a/.github/workflows/publish_meshes.yml +++ b/.github/workflows/publish_meshes.yml @@ -23,23 +23,23 @@ jobs: echo "REPO_OWNER=${GITHUB_REPOSITORY_OWNER,,}" >>${GITHUB_ENV} - name: Checkout - uses: actions/checkout@v4 + uses: actions/checkout@v6 with: submodules: true - name: Login to GHCR - uses: docker/login-action@v3 + uses: docker/login-action@v4 with: registry: ghcr.io username: ${{ github.repository_owner }} password: ${{ secrets.GITHUB_TOKEN }} - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 + uses: docker/setup-buildx-action@v4 - name: Docker meta id: meta - uses: docker/metadata-action@v5 + uses: docker/metadata-action@v6 with: images: ghcr.io/${{ env.REPO_OWNER }}/ximeshes tags: | @@ -50,7 +50,7 @@ jobs: org.opencontainers.image.description=Line-of-sight and navigation meshes for use with LandSandBoat server. - name: Build and push - uses: docker/build-push-action@v6 + uses: docker/build-push-action@v7 env: BUILDX_NO_DEFAULT_ATTESTATIONS: 1 with: diff --git a/.github/workflows/runner_build.yml b/.github/workflows/runner_build.yml index 2af1a4a5fdd..f61a85df143 100644 --- a/.github/workflows/runner_build.yml +++ b/.github/workflows/runner_build.yml @@ -64,7 +64,7 @@ jobs: steps: - name: Download changed files artifact if: ${{ inputs.optional_build }} - uses: actions/download-artifact@v4 + uses: actions/download-artifact@v8 with: name: changed-files @@ -92,7 +92,7 @@ jobs: - name: Checkout if: ${{ env.SKIP_BUILD != 'true' }} - uses: actions/checkout@v4 + uses: actions/checkout@v6 with: fetch-depth: 1 @@ -174,21 +174,21 @@ jobs: - name: Setup MSVC if: ${{ runner.os == 'Windows' && env.SKIP_BUILD != 'true' }} - uses: TheMrMilchmann/setup-msvc-dev@v3 + uses: TheMrMilchmann/setup-msvc-dev@v4 with: arch: x64 - name: Setup sccache if: ${{ env.SKIP_BUILD != 'true' }} - uses: mozilla-actions/sccache-action@v0.0.9 + uses: mozilla-actions/sccache-action@v0.0.10 with: disable_annotations: ${{ !inputs.save_cache }} - name: Setup Python if: ${{ env.SKIP_BUILD != 'true' }} - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: - python-version: '3.12' + python-version: '3.14' - name: Install Python codegen deps if: ${{ env.SKIP_BUILD != 'true' }} @@ -208,7 +208,7 @@ jobs: - name: Restore build cache if: ${{ env.SKIP_BUILD != 'true' }} id: restore_build - uses: actions/cache/restore@v4 + uses: actions/cache/restore@v5 env: cmake_hash: ${{ hashFiles('**/CMakeLists.txt', '**/*.cmake') }} source_hash: ${{ hashFiles('src/**/*', 'ext/**/*') }} @@ -235,7 +235,7 @@ jobs: - name: Upload artifact if: ${{ inputs.upload_artifact && env.SKIP_BUILD != 'true' }} - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@v7 with: name: ${{ format('LSB_{0}_{1}_{2}', runner.os, inputs.build_type, github.sha) }} path: | @@ -244,7 +244,7 @@ jobs: - name: Cache build if: ${{ inputs.save_cache && env.SKIP_BUILD != 'true' && steps.restore_build.outputs.cache-hit != 'true' }} - uses: actions/cache/save@v4 + uses: actions/cache/save@v5 with: path: build key: ${{ steps.restore_build.outputs.cache-primary-key }} diff --git a/.github/workflows/runner_test.yml b/.github/workflows/runner_test.yml index 193986abf7e..79dad2a9e67 100644 --- a/.github/workflows/runner_test.yml +++ b/.github/workflows/runner_test.yml @@ -53,7 +53,7 @@ jobs: XI_NETWORK_SQL_LOGIN: xiadmin XI_NETWORK_SQL_PASSWORD: 'password' steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 1 submodules: recursive # For navmeshes @@ -109,10 +109,10 @@ jobs: ${{ env.MYSQL_CMD }} -e "GRANT ALL PRIVILEGES ON ${{ env.XI_NETWORK_SQL_DATABASE }}.* TO '${{ env.XI_NETWORK_SQL_LOGIN }}'@'%';" ${{ env.MYSQL_CMD }} -e "FLUSH PRIVILEGES;" - - uses: actions/setup-python@v5 + - uses: actions/setup-python@v6 id: setup_python with: - python-version: '3.12' + python-version: '3.14' - name: Install Python dependencies run: | @@ -131,14 +131,14 @@ jobs: - name: Download artifact if: ${{ github.event_name == 'pull_request' }} - uses: actions/download-artifact@v4 + uses: actions/download-artifact@v8 with: name: ${{ format('LSB_{0}_{1}_{2}', runner.os, inputs.build_type, github.sha) }} path: . - name: Download previous artifact if: ${{ github.event_name == 'workflow_run' || github.event_name == 'workflow_dispatch' }} - uses: dawidd6/action-download-artifact@v3 + uses: dawidd6/action-download-artifact@v21 with: run_id: ${{ github.event.workflow_run.id }} name: ${{ format('LSB_{0}_{1}_{2}', runner.os, inputs.build_type, github.sha) }} @@ -188,7 +188,7 @@ jobs: - name: Startup checks if: ${{ inputs.startup_checks }} id: startup_checks - uses: nick-fields/retry@v3 + uses: nick-fields/retry@v4 with: timeout_minutes: 10 max_attempts: 3 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 413ebb72371..d7824d7d524 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -25,7 +25,7 @@ jobs: shell: bash steps: - run: git config --global --add safe.directory $GITHUB_WORKSPACE - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 0 @@ -47,10 +47,13 @@ jobs: shell: bash steps: - run: git config --global --add safe.directory $GITHUB_WORKSPACE - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 0 + - name: Generate codegen Lua enums + run: python -m tools.codegen "$RUNNER_TEMP/codegen-out" + - name: Run Lua Language Server id: run_lls run: python ./tools/ci/lua_lang_server.py diff --git a/docker/alpine.Dockerfile b/docker/alpine.Dockerfile index c0f775ff6c1..3bc171c6604 100644 --- a/docker/alpine.Dockerfile +++ b/docker/alpine.Dockerfile @@ -3,7 +3,7 @@ ######## # Base # ######## -ARG BASE_TAG=3.22 +ARG BASE_TAG=3.24 FROM --platform=$BUILDPLATFORM alpine:$BASE_TAG AS base # Install runtime dependencies. @@ -56,7 +56,7 @@ SHELL ["/bin/bash", "-c"] ########### FROM base AS staging -ARG LLVM_VERSION=20 +ARG LLVM_VERSION=22 # Install build dependencies. RUN --mount=type=cache,target=/var/cache/apk,id=cache-apk,sharing=locked < /dev/null || true @@ -188,13 +186,14 @@ USER $UNAME COPY --chown=$UNAME:$UGROUP LICENSE /server/LICENSE COPY --chown=$UNAME:$UGROUP res/compress.dat res/decompress.dat /server/res/ -COPY --chown=$UNAME:$UGROUP scripts /server/scripts COPY --chown=$UNAME:$UGROUP sql /server/sql COPY --chown=$UNAME:$UGROUP tools /server/tools COPY --chown=$UNAME:$UGROUP modules /server/modules COPY --chown=$UNAME:$UGROUP settings /server/settings COPY --chown=$UNAME:$UGROUP --from=staging $VIRTUAL_ENV $VIRTUAL_ENV +COPY --chown=$UNAME:$UGROUP --from=build /server/data /server/data +COPY --chown=$UNAME:$UGROUP --from=build /server/scripts /server/scripts COPY --chown=$UNAME:$UGROUP --from=build /server/xi_* /server/ COPY --chown=$UNAME:$UGROUP --from=build /server/build.log /server/build.log diff --git a/docker/ubuntu.Dockerfile b/docker/ubuntu.Dockerfile index 7e9d6bdefa9..4ecc87eea4f 100644 --- a/docker/ubuntu.Dockerfile +++ b/docker/ubuntu.Dockerfile @@ -3,7 +3,7 @@ ######## # Base # ######## -ARG BASE_TAG=24.04 +ARG BASE_TAG=26.04 FROM --platform=$BUILDPLATFORM ubuntu:$BASE_TAG AS base ARG DEBIAN_FRONTEND=noninteractive @@ -63,8 +63,8 @@ SHELL ["/bin/bash", "-c"] ########### FROM base AS staging -ARG GCC_VERSION=14 -ARG LLVM_VERSION=20 +ARG GCC_VERSION=15 +ARG LLVM_VERSION=22 # Install build dependencies. RUN --mount=type=cache,target=/var/cache/apt,id=cache-apt,sharing=locked \ @@ -151,7 +151,6 @@ COPY --chown=$UNAME:$UGROUP \ --exclude=.git \ --exclude=navmeshes/** \ --exclude=ximeshes/** \ - --exclude=scripts \ --exclude=sql \ . /server @@ -164,7 +163,6 @@ ENV CCACHE_DIR=/xiadmin/.ccache RUN --mount=type=cache,target=/xiadmin/build,uid=$UID,gid=$GID,id=build-ubuntu-$COMPILER-$CMAKE_BUILD_TYPE-tracy$TRACY_ENABLE-pch$PCH_ENABLE \ --mount=type=cache,target=/xiadmin/.ccache,uid=$UID,gid=$GID,id=ccache-ubuntu-$COMPILER-$CMAKE_BUILD_TYPE-tracy$TRACY_ENABLE-pch$PCH_ENABLE \ --mount=type=bind,source=.git,target=/server/.git \ - --mount=type=bind,source=scripts,target=/server/scripts \ --mount=type=bind,source=sql,target=/server/sql < /dev/null || true @@ -200,13 +198,14 @@ USER $UNAME COPY --chown=$UNAME:$UGROUP LICENSE /server/LICENSE COPY --chown=$UNAME:$UGROUP res/compress.dat res/decompress.dat /server/res/ -COPY --chown=$UNAME:$UGROUP scripts /server/scripts COPY --chown=$UNAME:$UGROUP sql /server/sql COPY --chown=$UNAME:$UGROUP tools /server/tools COPY --chown=$UNAME:$UGROUP modules /server/modules COPY --chown=$UNAME:$UGROUP settings /server/settings COPY --chown=$UNAME:$UGROUP --from=staging $VIRTUAL_ENV $VIRTUAL_ENV +COPY --chown=$UNAME:$UGROUP --from=build /server/data /server/data +COPY --chown=$UNAME:$UGROUP --from=build /server/scripts /server/scripts COPY --chown=$UNAME:$UGROUP --from=build /server/xi_* /server/ COPY --chown=$UNAME:$UGROUP --from=build /server/build.log /server/build.log diff --git a/ext/CMakeLists.txt b/ext/CMakeLists.txt index 3159a546e43..13c50cb3455 100644 --- a/ext/CMakeLists.txt +++ b/ext/CMakeLists.txt @@ -59,14 +59,14 @@ endif(TRACY_ENABLE) CPMAddPackage( NAME fmt GITHUB_REPOSITORY fmtlib/fmt - GIT_TAG 11.2.0 + GIT_TAG 12.1.0 SYSTEM ON ) # defines: fmt::fmt CPMAddPackage( NAME spdlog GITHUB_REPOSITORY gabime/spdlog - GIT_TAG v1.15.3 + GIT_TAG v1.17.0 SYSTEM ON OPTIONS "SPDLOG_ENABLE_PCH ON" @@ -76,11 +76,9 @@ CPMAddPackage( CPMAddPackage( NAME recastnavigation GITHUB_REPOSITORY recastnavigation/recastnavigation - GIT_TAG bd98d84c274ee06842bf51a4088ca82ac71f8c2d + GIT_TAG 1078bfe346d9bb560faa748c8fde2e7aae73a3ab SYSTEM ON OPTIONS - # TODO: Remove this once recast is updated to use CMake 3.5+, it's currently set to what we use in the root CMakeLists.txt - "CMAKE_POLICY_VERSION_MINIMUM 3.20" "RECASTNAVIGATION_DEMO OFF" "RECASTNAVIGATION_TESTS OFF" "RECASTNAVIGATION_EXAMPLES OFF" @@ -127,8 +125,8 @@ CPMAddPackage( CPMAddPackage( NAME efsw - GITHUB_REPOSITORY zach2good/efsw - GIT_TAG c37c7e0fc6bbd63659edeba458273c35a51513da # master + GITHUB_REPOSITORY SpartanJ/efsw + GIT_TAG 22f17a0bcdf3a4edf61f8b14328391463389e548 # master SYSTEM ON OPTIONS "VERBOSE OFF" diff --git a/src/common/database.h b/src/common/database.h index 68d9a45c6e4..bb89abe2fef 100644 --- a/src/common/database.h +++ b/src/common/database.h @@ -500,7 +500,7 @@ class ResultSetWrapper final return resultSet_->isNull(key.c_str()); } - auto query() const + auto query() const -> const std::string& { return query_; } diff --git a/src/map/ai/controllers/pet_controller.cpp b/src/map/ai/controllers/pet_controller.cpp index 121d33834f0..4fb31ff4333 100644 --- a/src/map/ai/controllers/pet_controller.cpp +++ b/src/map/ai/controllers/pet_controller.cpp @@ -172,6 +172,8 @@ auto CPetController::DoRoamTick(timer::time_point tick) -> Task } PPet->PAI->PathFind->FollowPath(m_Tick); + + co_return; } bool CPetController::PetIsHealing() diff --git a/src/map/ai/controllers/trust_controller.cpp b/src/map/ai/controllers/trust_controller.cpp index c2bb18d583d..8f2c1b55391 100644 --- a/src/map/ai/controllers/trust_controller.cpp +++ b/src/map/ai/controllers/trust_controller.cpp @@ -120,6 +120,8 @@ auto CTrustController::Tick(timer::time_point tick) -> Task { co_await DoRoamTick(tick); } + + co_return; } auto CTrustController::DoCombatTick(timer::time_point tick) -> Task @@ -251,6 +253,8 @@ auto CTrustController::DoCombatTick(timer::time_point tick) -> Task PTrust->PAI->EventHandler.triggerListener("COMBAT_TICK", PTrust, PMaster, PTarget); } + + co_return; } auto CTrustController::DoNonCombatTick(timer::time_point tick) -> Task diff --git a/src/map/conquest_data.cpp b/src/map/conquest_data.cpp index 760d37233d6..9034422f4a6 100644 --- a/src/map/conquest_data.cpp +++ b/src/map/conquest_data.cpp @@ -131,7 +131,7 @@ uint8 ConquestData::getPrevRegionControlCount(NATION_TYPE nation) const return count; } -auto ConquestData::getRegionControls() -> std::vector const +auto ConquestData::getRegionControls() const -> const std::vector& { return regionControls; } diff --git a/src/map/conquest_data.h b/src/map/conquest_data.h index c8badc47f47..35cf142fcff 100644 --- a/src/map/conquest_data.h +++ b/src/map/conquest_data.h @@ -1,4 +1,4 @@ -/* +/* =========================================================================== Copyright (c) 2023 LandSandBoat Dev Teams @@ -75,7 +75,7 @@ class ConquestData // // Gets the array of region controls, indexed by regionId. // - auto getRegionControls() -> const std::vector; + auto getRegionControls() const -> const std::vector&; // // Adds the given influence points to the given nation for the given diff --git a/src/map/entities/automatonentity.cpp b/src/map/entities/automatonentity.cpp index c38d3e60418..ea8d82a4558 100644 --- a/src/map/entities/automatonentity.cpp +++ b/src/map/entities/automatonentity.cpp @@ -96,7 +96,7 @@ void CAutomatonEntity::burdenTick() } } -auto CAutomatonEntity::getBurden() const -> std::array +auto CAutomatonEntity::getBurden() const -> const std::array& { return m_Burden; } diff --git a/src/map/entities/automatonentity.h b/src/map/entities/automatonentity.h index a3b3c375d23..0ff638c8d02 100644 --- a/src/map/entities/automatonentity.h +++ b/src/map/entities/automatonentity.h @@ -54,7 +54,7 @@ class CAutomatonEntity : public CPetEntity auto getElementCapacity(uint8 element) const -> uint8; void burdenTick(); - auto getBurden() const -> std::array; + auto getBurden() const -> const std::array&; void setAllBurden(uint8 burden); void setBurdenArray(std::array burdenArray); auto addBurden(uint8 element, int8 burden) -> uint8; diff --git a/src/map/entities/charentity.cpp b/src/map/entities/charentity.cpp index 5422e7a98dd..8b2f8fcb178 100644 --- a/src/map/entities/charentity.cpp +++ b/src/map/entities/charentity.cpp @@ -1157,6 +1157,8 @@ auto CCharEntity::Tick(timer::time_point tick) -> Task { gardenutils::UpdateGardening(this, SendPacket::Yes); } + + co_return; } void CCharEntity::PostTick() diff --git a/src/map/lua/lua_item_puppet.cpp b/src/map/lua/lua_item_puppet.cpp index 07645a5d1a6..65052b86808 100644 --- a/src/map/lua/lua_item_puppet.cpp +++ b/src/map/lua/lua_item_puppet.cpp @@ -1,4 +1,4 @@ -/* +/* =========================================================================== Copyright (c) 2026 LandSandBoat Dev Teams diff --git a/src/map/lua/luautils.cpp b/src/map/lua/luautils.cpp index f2f3924903e..91d014b98eb 100644 --- a/src/map/lua/luautils.cpp +++ b/src/map/lua/luautils.cpp @@ -1012,15 +1012,15 @@ void OnEntityLoad(CBaseEntity* PEntity) return; } - const auto zoneName = PEntity->loc.zone->getName(); - const auto name = PEntity->getName(); + const auto zoneName = PEntity->loc.zone->getName(); + const auto& name = PEntity->getName(); CacheLuaObjectFromFile(fmt::format("./scripts/zones/{}/npcs/{}.lua", zoneName, name)); } break; case TYPE_MOB: { - const auto zoneName = PEntity->loc.zone->getName(); - const auto name = PEntity->getName(); + const auto zoneName = PEntity->loc.zone->getName(); + const auto& name = PEntity->getName(); CacheLuaObjectFromFile(fmt::format("./scripts/zones/{}/mobs/{}.lua", zoneName, name)); } break; @@ -6061,7 +6061,7 @@ auto GetSynergyRecipeByID(uint32 id) -> sol::table { return sol::lua_nil; } - const auto result = *maybeResult; + const auto& result = *maybeResult; sol::table table = lua.create_table(); @@ -6132,7 +6132,7 @@ auto GetSynergyRecipeByTrade(CLuaTradeContainer luaTradeContainer) -> sol::table { return sol::lua_nil; } - const auto result = *maybeResult; + const auto& result = *maybeResult; sol::table table = lua.create_table(); diff --git a/src/map/packets/c2s/0x036_item_transfer.cpp b/src/map/packets/c2s/0x036_item_transfer.cpp index 3af79a44e2f..d979fa1c318 100644 --- a/src/map/packets/c2s/0x036_item_transfer.cpp +++ b/src/map/packets/c2s/0x036_item_transfer.cpp @@ -1,4 +1,4 @@ -/* +/* =========================================================================== Copyright (c) 2025 LandSandBoat Dev Teams @@ -36,10 +36,10 @@ const auto auditTrade = [](Scheduler& scheduler, CCharEntity* PChar, CBaseEntity { if (settings::get("map.AUDIT_PLAYER_TRADES")) { - const auto sender = PChar->id; - const auto senderName = PChar->getName(); - const auto receiver = PNpc->id; - const auto receiverName = PNpc->getName(); + const auto sender = PChar->id; + const auto& senderName = PChar->getName(); + const auto receiver = PNpc->id; + const auto& receiverName = PNpc->getName(); scheduler.postToWorkerThread( [itemId, quantity, sender, senderName, receiver, receiverName]() diff --git a/src/map/packets/c2s/0x0b5_chat_std.cpp b/src/map/packets/c2s/0x0b5_chat_std.cpp index a90e8f9e900..b23efa0ac4c 100644 --- a/src/map/packets/c2s/0x0b5_chat_std.cpp +++ b/src/map/packets/c2s/0x0b5_chat_std.cpp @@ -1,4 +1,4 @@ -/* +/* =========================================================================== Copyright (c) 2025 LandSandBoat Dev Teams @@ -63,9 +63,9 @@ const auto auditUnity = [](Scheduler& scheduler, CCharEntity* PChar, const std:: { if (settings::get("map.AUDIT_CHAT") && settings::get("map.AUDIT_UNITY")) { - const auto name = PChar->getName(); - const auto zoneId = PChar->getZone(); - const auto unityLeader = PChar->PUnityChat->getLeader(); + const auto& name = PChar->getName(); + const auto zoneId = PChar->getZone(); + const auto unityLeader = PChar->PUnityChat->getLeader(); scheduler.postToWorkerThread( [name, zoneId, unityLeader, rawMessage]() diff --git a/src/map/utils/instanceutils.cpp b/src/map/utils/instanceutils.cpp index 2beb0f7f129..e2f08923494 100644 --- a/src/map/utils/instanceutils.cpp +++ b/src/map/utils/instanceutils.cpp @@ -188,6 +188,8 @@ auto CheckInstance(Scheduler& scheduler, MapConfig config) -> Task auto loader = std::make_unique(instanceId, PRequester); loader->LoadInstance(); + + co_return; } auto LoadInstance(uint32 instanceid, CCharEntity* PRequester) -> void diff --git a/src/map/utils/moduleutils.cpp b/src/map/utils/moduleutils.cpp index faaffd6de1c..de43f3c1457 100644 --- a/src/map/utils/moduleutils.cpp +++ b/src/map/utils/moduleutils.cpp @@ -1,4 +1,4 @@ -/* +/* =========================================================================== Copyright (c) 2021 LandSandBoat Dev Teams diff --git a/src/map/utils/zoneutils.cpp b/src/map/utils/zoneutils.cpp index 62631d3640b..1d436af59e1 100644 --- a/src/map/utils/zoneutils.cpp +++ b/src/map/utils/zoneutils.cpp @@ -863,6 +863,8 @@ auto Initialize(Scheduler& scheduler, MapConfig config) -> Task lazyLoad.managedZones = std::set(zones.begin(), zones.end()); luautils::InitInteractionGlobal(); + + co_return; } auto ProcessLoadQueue(Scheduler& scheduler, MapConfig config) -> Task diff --git a/src/map/zone_entities.cpp b/src/map/zone_entities.cpp index 95a043f05a1..18ea1076d78 100644 --- a/src/map/zone_entities.cpp +++ b/src/map/zone_entities.cpp @@ -2154,12 +2154,12 @@ auto CZoneEntities::GetEffectCheckTime() const -> timer::time_point return m_EffectCheckTime; } -EntityList_t CZoneEntities::GetCharList() const +auto CZoneEntities::GetCharList() const -> const EntityList_t& { return m_charList; } -EntityList_t CZoneEntities::GetMobList() const +auto CZoneEntities::GetMobList() const -> const EntityList_t& { return m_mobList; } diff --git a/src/map/zone_entities.h b/src/map/zone_entities.h index 3830f8f02e4..a0c340e7f5f 100644 --- a/src/map/zone_entities.h +++ b/src/map/zone_entities.h @@ -86,10 +86,10 @@ class CZoneEntities CZone* GetZone(); - auto GetEffectCheckTime() const -> timer::time_point; - EntityList_t GetCharList() const; - EntityList_t GetMobList() const; - bool CharListEmpty() const; + auto GetEffectCheckTime() const -> timer::time_point; + auto GetCharList() const -> const EntityList_t&; + auto GetMobList() const -> const EntityList_t&; + bool CharListEmpty() const; void ForEachChar(const std::function& func); void ForEachMob(const std::function& func); diff --git a/src/test/lua/helpers/lua_client_entity_pair_events.cpp b/src/test/lua/helpers/lua_client_entity_pair_events.cpp index 7798686439e..1811e476f6a 100644 --- a/src/test/lua/helpers/lua_client_entity_pair_events.cpp +++ b/src/test/lua/helpers/lua_client_entity_pair_events.cpp @@ -1,4 +1,4 @@ -/* +/* =========================================================================== Copyright (c) 2025 LandSandBoat Dev Teams @@ -133,7 +133,7 @@ void CLuaClientEntityPairEvents::expect(sol::table expectedEvent) const if (updates.has_value()) { - const sol::table updateTable = updates.value(); + const sol::table& updateTable = updates.value(); for (const auto& pair : updateTable) { if (pair.second.is()) diff --git a/src/test/lua/lua_spy.cpp b/src/test/lua/lua_spy.cpp index f0149ce83b3..797a995af8a 100644 --- a/src/test/lua/lua_spy.cpp +++ b/src/test/lua/lua_spy.cpp @@ -50,7 +50,7 @@ auto CLuaSpy::original() const -> sol::object return original_; } -auto CLuaSpy::path() const -> std::string +auto CLuaSpy::path() const -> const std::string& { return path_; } diff --git a/src/test/lua/lua_spy.h b/src/test/lua/lua_spy.h index 2f704fd5f51..377640e7f3b 100644 --- a/src/test/lua/lua_spy.h +++ b/src/test/lua/lua_spy.h @@ -39,7 +39,7 @@ class CLuaSpy } auto original() const -> sol::object; - auto path() const -> std::string; + auto path() const -> const std::string&; virtual auto operator()(sol::variadic_args args) -> sol::as_returns_t>; static void Register(); diff --git a/src/test/lua/lua_test_entity.cpp b/src/test/lua/lua_test_entity.cpp index 84e73463ebe..396cfce78c2 100644 --- a/src/test/lua/lua_test_entity.cpp +++ b/src/test/lua/lua_test_entity.cpp @@ -1,4 +1,4 @@ -/* +/* =========================================================================== Copyright (c) 2025 LandSandBoat Dev Teams diff --git a/src/test/test_suite.cpp b/src/test/test_suite.cpp index d878f129f7f..58760e8ec62 100644 --- a/src/test/test_suite.cpp +++ b/src/test/test_suite.cpp @@ -104,12 +104,12 @@ auto TestSuite::sourceFile() const -> const std::string& return sourceFile_; } -auto TestSuite::fullName() const -> std::string +auto TestSuite::fullName() const -> const std::string& { return fullPath_; } -auto TestSuite::name() const -> std::string +auto TestSuite::name() const -> const std::string& { return name_; } diff --git a/src/test/test_suite.h b/src/test/test_suite.h index c17b046429b..483cb61b1c0 100644 --- a/src/test/test_suite.h +++ b/src/test/test_suite.h @@ -39,8 +39,8 @@ class TestSuite void setBeforeEachFunc(sol::protected_function func); void setAfterEachFunc(sol::protected_function func); - auto fullName() const -> std::string; - auto name() const -> std::string; + auto fullName() const -> const std::string&; + auto name() const -> const std::string&; auto childSuites() const -> const std::vector&; auto testCases() const -> const std::vector&;