ScrollView的Content的子节点触摸事件问题

CocosCreator 3.8.3

UI制作如上
SpriteSplash节点上有如下脚本

import { _decorator, Component, EventTouch, isValid, Node } from 'cc';
const { ccclass, property } = _decorator;

@ccclass('TowerBuildItem')
export class TowerBuildItem extends Component {

    protected start(): void {
        this.node.on(Node.EventType.TOUCH_START, this.onTouchStart, this);
        this.node.on(Node.EventType.TOUCH_END, this.onTouchEnd, this);
        this.node.on(Node.EventType.TOUCH_MOVE, this.onTouchMove, this);
        this.node.on(Node.EventType.TOUCH_CANCEL, this.onTouchCancel, this);
    }


    onTouchStart(e: EventTouch) {
        console.log("onTouchStart");
    }

    onTouchEnd(e: EventTouch) {
        console.log("onTouchEnd");
    }

    onTouchMove(e: EventTouch) {
        console.log("onTouchMove");
    }

    onTouchCancel(e: EventTouch) {
        console.log("onTouchCancel");
    }
}

运行结果1(刷新页面后,触摸移动,然后再节点内释放)

问题:

  1. onTouchCancel不该被触发
  2. onTouchEnd并没有被触发

运行结果2(刷新页面后,触摸移动,然后再节点外释放)

image

问题:

  1. onTouchCancel不该被触发

麻烦官方大佬和社区大佬帮看看是我用法有问题吗?

@minggo 大佬能帮看看吗?

你的用法没问题,应该是你触摸的有问题

应该是的,我大概想了下应该是滑动列表取消了触摸事件导致的,我先滑动列表去掉了

另外这是什么问题啊,给这个节点设置相同的坐标,最后打印结果,和显示位置差的都很多。

父节点一致,设置坐标一致,但是表现和实际坐标点不一致,用了setPosition和worldPosition = 都是这样的结果


真写的不会搞了,这都是什么情况啊。刚刚更新到3.8.4还是这样