From 7c9cbe227eec681f5af3d47241acda954c318973 Mon Sep 17 00:00:00 2001 From: James Chen Date: Wed, 22 Jan 2025 15:57:30 +0800 Subject: [PATCH] Fix ci issues. --- native/cocos/core/scene-graph/Node.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/native/cocos/core/scene-graph/Node.cpp b/native/cocos/core/scene-graph/Node.cpp index cadfbad0206..62899579cfc 100644 --- a/native/cocos/core/scene-graph/Node.cpp +++ b/native/cocos/core/scene-graph/Node.cpp @@ -767,8 +767,8 @@ bool Node::getParentWorldMatrixNoSkew(Node *parent, Mat4 *out) { if (startNode) { out->set(startNode->_parent->_worldMatrix); // Set the first no-skew node's world matrix to out. auto iter = std::find(ancestors.begin(), ancestors.end(), startNode); - int start = iter - ancestors.begin(); - for (int i = start; i >= 0; --i) { + long start = static_cast(iter - ancestors.begin()); + for (long i = start; i >= 0; --i) { const auto *node = ancestors[i]; Mat4::fromRTS(node->_localRotation, node->_localPosition, node->_localScale, &curMat4); Mat4::multiply(*out, curMat4, out);