cocos-engine icon indicating copy to clipboard operation
cocos-engine copied to clipboard

fix #17484: 修复tsx文件对象层自定义属性读取错误

Open Jerry457 opened this issue 1 year ago • 1 comments

Greptile Summary

This pull request addresses issue #17484 by fixing the error in reading custom properties of object layers from TSX files.

  • Added properties field to TMXObject interface in cocos/tiledmap/tiled-types.ts.
  • Updated getPropertyList function in cocos/tiledmap/tmx-xml-parser.ts to use querySelectorAll for better property selection.
  • Modified parseObjectGroup method in cocos/tiledmap/tmx-xml-parser.ts to correctly assign properties to object layers.

Jerry457 avatar Aug 02 '24 12:08 Jerry457

Interface Check Report

! WARNING this pull request has changed these public interfaces:

@@ -19753,9 +19753,9 @@
         export class frustum extends Frustum {
             constructor();
         }
     }
-    export const VERSION = "3.8.4";
+    export const VERSION = "3.8.5";
     /**
      * @en
      * The main namespace of Cocos engine, all engine core classes, functions, properties and constants are defined in this namespace.
      * @zh
@@ -63959,15 +63959,15 @@
              * @en The event type indicates mouse leaves the window or canvas. Only Windows, macOS or web PC can
              * trigger this event.
              * @zh 当鼠标离开窗口或者 canvas 时发出该消息。只有 Windows、macOS 或者 PC web 会触发该事件。
              */
-            MOUSE_LEAVE = "mouse-leave-window",
+            MOUSE_LEAVE = "mouse-leave",
             /**
              * @en The event type indicates mouse enters the window or canvas. Only Windows, macOS or web PC can
              * trigger this event.
              * @zh 当鼠标进入窗口或者 canvas 时发出该消息。只有 Windows、macOS 或者 PC web 会触发该事件。
              */
-            MOUSE_ENTER = "mouse-enter-window",
+            MOUSE_ENTER = "mouse-enter",
             /**
              * @en
              * The event type for mouse wheel events
              *
@@ -69631,8 +69631,9 @@
              */
             TEXT = 5
         }
         export interface _cocos_tiledmap_tiled_types__TMXObject {
+            properties: _cocos_tiledmap_tiled_types__PropertiesInfo;
             id: number | string;
             name: string;
             width: number;
             height: number;

github-actions[bot] avatar Aug 02 '24 12:08 github-actions[bot]

@Jerry457 There is also a ci error

qiuguohua avatar Sep 14 '24 08:09 qiuguohua