From 94f811d31f1c5f3f6185def9c2d3e1bc647693d0 Mon Sep 17 00:00:00 2001 From: Unreal Karaulov Date: Tue, 19 Nov 2024 18:05:47 +0300 Subject: [PATCH] fix --- .gitignore | 1 + src/nav/LeafNavMesh.cpp | 2 +- src/util/Polygon3D.cpp | 6 +++--- vs-project/bspguy.vcxproj | 4 ++-- vs-project/fmt/fmt.vcxproj | 4 ++-- 5 files changed, 9 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index 74f7062e..187970af 100644 --- a/.gitignore +++ b/.gitignore @@ -80,3 +80,4 @@ ascript/angelscript/projects/msvc2022/Debug/angelscript.vcxproj.FileListAbsolute /vs-project/glfw/src/ReleaseXPx86 /vs-project/fmt/fmt.dir /vs-project/glfw/src/glfw.dir +/ascript/angelscript/projects/msvc2022/x64 diff --git a/src/nav/LeafNavMesh.cpp b/src/nav/LeafNavMesh.cpp index fceb4840..f5dafd2a 100644 --- a/src/nav/LeafNavMesh.cpp +++ b/src/nav/LeafNavMesh.cpp @@ -168,7 +168,7 @@ int LeafNavMesh::getNodeIdx(Bsp* map, Entity* ent) { boxPolys[i] = std::vector{ face.v1.pos, face.v2.pos, face.v3.pos, face.v6.pos }; } - for (size_t i = 0; i < nodes.size(); i++) { + for (int i = 0; i < (int)nodes.size(); i++) { LeafNode& mesh = nodes[i]; for (size_t k = 0; k < mesh.leafFaces.size(); k++) { diff --git a/src/util/Polygon3D.cpp b/src/util/Polygon3D.cpp index 26f11397..eee28a6c 100644 --- a/src/util/Polygon3D.cpp +++ b/src/util/Polygon3D.cpp @@ -200,7 +200,7 @@ std::vector> Polygon3D::cut(Line2D cutLine) { std::vector newLocalVerts; for (size_t i = 0; i < localVerts.size(); i++) { - int next = (i + 1) % localVerts.size(); + size_t next = (i + 1) % localVerts.size(); vec2 e1 = localVerts[i]; vec2 e2 = localVerts[next]; Line2D edge(e1, e2); @@ -373,11 +373,11 @@ Polygon3D Polygon3D::merge(const Polygon3D& mergePoly) { int sharedEdges = 0; int commonEdgeStart1 = -1, commonEdgeEnd1 = -1; int commonEdgeStart2 = -1, commonEdgeEnd2 = -1; - for (size_t i = 0; i < verts.size(); i++) { + for (int i = 0; i < (int)verts.size(); i++) { const vec3& e1 = verts[i]; const vec3& e2 = verts[(i + 1) % verts.size()]; - for (size_t k = 0; k < mergePoly.verts.size(); k++) { + for (int k = 0; k < (int)mergePoly.verts.size(); k++) { const vec3& other1 = mergePoly.verts[k]; const vec3& other2 = mergePoly.verts[(k + 1) % mergePoly.verts.size()]; diff --git a/vs-project/bspguy.vcxproj b/vs-project/bspguy.vcxproj index d98c0a31..c3ecb017 100644 --- a/vs-project/bspguy.vcxproj +++ b/vs-project/bspguy.vcxproj @@ -185,7 +185,7 @@ true false Level4 - %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_ITERATOR_DEBUG_LEVEL=1 + %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NOMINMAX;_CRT_SECURE_NO_WARNINGS; $(IntDir) stdcpplatest false @@ -265,7 +265,7 @@ del "$(TargetDir)bspguy.cfg_bak" true false Level4 - %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_ITERATOR_DEBUG_LEVEL=1 + %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NOMINMAX;_CRT_SECURE_NO_WARNINGS; $(IntDir) stdcpplatest false diff --git a/vs-project/fmt/fmt.vcxproj b/vs-project/fmt/fmt.vcxproj index ccf772ba..a932631b 100644 --- a/vs-project/fmt/fmt.vcxproj +++ b/vs-project/fmt/fmt.vcxproj @@ -159,7 +159,7 @@ NotUsing MultiThreadedDebug false - %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NDEBUG;_ITERATOR_DEBUG_LEVEL=1 + %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NDEBUG; $(IntDir) false true @@ -196,7 +196,7 @@ NotUsing MultiThreadedDebug false - %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NDEBUG;_ITERATOR_DEBUG_LEVEL=1 + %(PreprocessorDefinitions);WIN32;_WINDOWS;GLEW_STATIC;NDEBUG; $(IntDir) false true