This extension was fully tested on GameMaker: Studio v1.4.1772, compiling for both iOS and iOS (YYC). It was also successfully tested with GameMaker Studio 2 for Windows (v18.104.22.168), although it is not officially supported at the moment.
This extension package contains an example, in the form of GameMaker: Studio resources (sprites, objects, rooms, etc.) that can be imported in your project. This example is completely optional; it is meant to showcase what can be achieved with the extension, as well as help get familiarized with its functionality and quickly dive into the code. It is not meant to be used “as is”, and it doesn’t replace this documentation. If you wish to check out the example, we recommend adding the extension to an empty project, importing all the resources, moving the room that fits your device (phone or tablet) to the first position, and running it on your iOS or Android device (note: for Android, you have to create a full APK).
Below is the complete list of functions. If you are experiencing any issue, please make sure to check out the “Troubleshooting” section at the bottom of this document. If you don’t find an answer to your question, don’t hesitate to contact us through the YoYo Games Marketplace (link at the top). Thank you!
Returns whether 3D Touch is supported and enabled on the current device.
Gets the pressure applied to the screen for the given touch.
touch The touch index, starting from
0 (first finger that touched the screen). This argument is equivalent to the
deviceargument in GameMaker: Studio’s
Returns: Real (Double) The force of the touch, between
-1 if the touch is inactive or 3D Touch is unavailable.
Gets the maximum possible force that can be obtained by
Returns: Real (Double) The maximum force, or
-1 if the user hasn’t yet touched the screen or 3D Touch is unavailable.
Please disable the feature in GameMaker: Studio that detects double taps as
mb_right instead of two individual taps by calling
device_mouse_dbclick_enable(false) at the beginning of your game. You should get better results.
For 3D Touch to be available to the application, the device not only needs to support it but 3D Touch must be enabled in iOS’s Accessibility settings.
ios3dtouch_to prevent conflicts