文件名称:EventListenerGesture:用于手势的Cocos2d-x EventListener(轻按,LongTap,轻扫)
文件大小:3KB
文件格式:ZIP
更新时间:2024-06-01 18:29:00
C++
EventListenerGesture 用于手势的cocos2d-x3 EventListener(轻按,LongTap,滑动)。 例子 auto listener = EventListenerGesture::create(); // if dont set this value is 0.1f. listener-> setLongTapThreshouldSeconds ( 1 . 0f ); // if dont set this value is 10.0f. listener-> setSwipeThreshouldDistance ( 150 . 0f ); listener->onTap = [](Vec2 vec2){ log ( " onTap called. " );}; listener->onLongTapBegan = [](Vec2 vec2){ log
【文件预览】:
EventListenerGesture-master
----EventListenerGesture.h(2KB)
----EventListenerGesture.cpp(5KB)
----README.md(1KB)