当前位置:网站首页>【Cocos Creator 3.5.1】input.on的使用
【Cocos Creator 3.5.1】input.on的使用
2022-06-27 05:34:00 【CN-Dust】
input.on代替2.x中的cc.director.on或者this.node.on
使用方式:(会在上方自动生成import内容)
input.on(Input.EventType.MOUSE_UP, this.onMouseUp, this);
描述:
(alias) const input: Input
import input
@en — The singleton of the Input class, this singleton manages all events of input. include: touch, mouse, accelerometer and keyboard.
@zh — 输入类单例,该单例管理所有的输入事件,包括:触摸、鼠标、加速计 和 键盘。
@example
input.on(Input.EventType.DEVICEMOTION, this.onDeviceMotionEvent, this);
input.off(Input.EventType.DEVICEMOTION, this.onDeviceMotionEvent, this);
边栏推荐
- Halon common affine transformation operators
- Ad22 Gerber files Click to open the Gerber step interface. Official solutions to problems
- 010 C language foundation: C function
- Opencv implements object tracking
- 使用域名转发mqtt协议,避坑指南
- Open the door small example to learn ten use case diagrams
- Two position relay rxmvb2 r251 204 110dc
- AcWing 第 57 场周赛---BC题挺好
- EPICS记录参考5 -- 数组模拟输入记录Array Analog Input (aai)
- 双位置继电器HJWS-9440
猜你喜欢

流媒体协议初探(MPEG2-TS、RTSP、RTP、RTCP、SDP、RTMP、HLS、HDS、HSS、MPEG-DASH)

Implementation of easyexcel's function of merging cells with the same content and dynamic title

Redis high availability cluster (sentry, cluster)

论文解读(LG2AR)《Learning Graph Augmentations to Learn Graph Representations》

Pycharm 中 Terminal 无法进入 venv 环境的问题

双位置继电器RXMD2-1MRK001984 DC220V

Codeforces Round #802 (Div. 2)

pycharm 如何安装 package
![Mechanical transcoding journal [17] template, STL introduction](/img/78/926db660139fda3d31cceccad7096c.png)
Mechanical transcoding journal [17] template, STL introduction

Two position relay xjls-8g/220
随机推荐
Terminal in pychar cannot enter the venv environment
【FPGA】 基于FPGA分频,倍频设计实现
清华大学开源软件镜像站网址
How JQ gets the reciprocal elements
Asp. Net core6 websocket simple case
网易云音乐params和encSecKey参数生成代码
Vue学习笔记(五)Vue2页面跳转问题 | vue-router路由概念、分类与使用 | 编程式路由导航 | 路由组件的缓存 | 5种路由导航守卫 | 嵌套路由 | Vue2项目的打包与部署
Comprehensive application of OpenCV in contour detection and threshold processing
021 basics of C language: recursion, variable parameters
OpenCV的轮廓检测和阈值处理综合运用
Get system volume across platforms in unity
Two position relay xjls-8g/220
Interview: what are the positioning methods in selenium? Which one do you use most?
Epics record reference 5 -- array analog input recordarray analog input (AAI)
躲避小行星游戏
牛客练习赛101-C 推理小丑---位运算+思维
AD22 gerber files 点开 gerber steup 界面 有问题 官方解决方法
Edge loads web pages in IE mode - edge sets ie compatibility
jq怎么获取倒数的元素
认知篇----2022高考志愿该如何填报