diff options
-rw-r--r-- | .github/workflows/static_checks.yml | 2 | ||||
-rw-r--r-- | scene/resources/world_2d.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/.github/workflows/static_checks.yml b/.github/workflows/static_checks.yml index bcba4c36d9..587f5a6ba6 100644 --- a/.github/workflows/static_checks.yml +++ b/.github/workflows/static_checks.yml @@ -12,7 +12,7 @@ jobs: run: | sudo apt-get update -qq sudo apt-get install -qq dos2unix recode clang-format - pip3 install --user black pygments + sudo pip3 install black pygments - name: File formatting checks (file_format.sh) run: | diff --git a/scene/resources/world_2d.cpp b/scene/resources/world_2d.cpp index 1c753fdb91..d2bc2bea31 100644 --- a/scene/resources/world_2d.cpp +++ b/scene/resources/world_2d.cpp @@ -211,7 +211,7 @@ struct SpatialIndexer2D { List<VisibilityNotifier2D *> added; List<VisibilityNotifier2D *> removed; - int visible_cells = (end.x - begin.x) * (end.y - begin.y); + uint64_t visible_cells = (uint64_t)(end.x - begin.x) * (uint64_t)(end.y - begin.y); if (visible_cells > 10000) { //well you zoomed out a lot, it's your problem. To avoid freezing in the for loops below, we'll manually check cell by cell |