Open jhyoo2 opened 7 months ago
've found that the issue was occurring because the touch pen events were being recognized as mouse events. Modifying the following line in the AndroidPlatform.cpp file resolved the issue. Since we've only released the game for mobile, I don't think it will be a significant problem, but just to be safe, could you check if there's any potential issue for future problems?
Original: // bool isMouseEvent = motionEvent->pointerCount > 0 && (motionEvent->pointers[0].toolType == AMOTION_EVENT_TOOL_TYPE_STYLUS || motionEvent->pointers[0].toolType == AMOTION_EVENT_TOOL_TYPE_MOUSE);
Modified: bool isMouseEvent = motionEvent->pointerCount > 0 && (motionEvent->pointers[0].toolType == AMOTION_EVENT_TOOL_TYPE_MOUSE);
Thanks for reporting the issue, we will take a look.
Cocos Creator version
3.8.1
System information
Android
Issue description
Hello developer friends! I’m one of the big fans of cocos – this engine has made game development possible for me.
However, there seems to be an issue with the latest update. We were using version 3.7.2 until a few weeks ago and then upgraded our engine. After this upgrade, we’ve been continuously receiving reviews that the Samsung models’ S-Pen is no longer working. It seems like the engine is not recognizing touches from the S-Pen as regular touch inputs.
Relevant error log output
No response
Steps to reproduce
use s-pen to play game
Minimal reproduction project
No response