mirror of
https://github.com/cocos/cocos4.git
synced 2026-11-19 14:52:40 +08:00
fix boneIdx check error (#264)
* fix boneIdx check error * simplify check
This commit is contained in:
@@ -1589,7 +1589,7 @@ export class Skeleton extends UIRenderer {
|
||||
const socket = this._sockets[i];
|
||||
if (socket.path && socket.target) {
|
||||
const boneIdx = this._cachedSockets.get(socket.path);
|
||||
if (!boneIdx) {
|
||||
if (boneIdx == null || boneIdx < 0) {
|
||||
error(`Skeleton data does not contain path ${socket.path}`);
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user