ReplayKit for iOS9 and Android 5.0
Works on iOS9 and above and Android 5.0 and above
For Stencyl 3.4 and above
Stencyl extension for “ReplayKit” for iOS9 and Android 5.0 . This extension allows you to easily integrate ReplayKit on your Stencyl game / application. (http://www.stencyl.com
)ReplayKit is only available on the following devices running iOS 9 or above; iPad Air 2, iPad Mini 2, iPad Mini 3, iPad 5 Air, iPhone 5s, iPhone 6 and iPhone 6 Plus.
On Android is ReplayKit only available on devices running Android 5.0 (Lollipop) or above.
For Android make sure you selected API 21 or higher in Mobile settings->version->Android Target version How to download this extension
Go to: http://byrobin.nl/store/product/replaykit-for-ios9-stencylopenfl/
Add the extension to the cart en proceed with checkout. After you successfully placed the order, you will get an e-mail with the download link or go to “My Account
” section where you can also find the download link.
Install the zip file: Go to : http://community.stencyl.com/index.php/topic,30432.0.htmlMain Features
- Recording video and shareVersion History2016-04-06
(0.0.1) First release2016-04-08
(0.0.2) Fix: Crash on iOS8 and lower.2016-10-01
– Android 5.0> support (works only on device thats running Android 5 or higher
– Added is Cancelled boolean block
– Added ask for Preview option in Initialize block (ask user to view video after recording)2016-10-03
(0.0.4) Update for iOS 10 startRecordingWithMicrophoneEnabled
is Deprecated in iOS 10, need to call startRecordingWithHandler
in iOS 10.2017-03-19
(0.0.5) Added Gradle support for openfl42017-03-21
(0.0.6) Fix: Audio stops playing after dismiss Preview, Added previewController didOpened/didClosed boolean block. (for pause your gameaudio when preview didopened and resume when closed)Documentation and Block ExamplesFor Android make sure you selected API 21 or higher in Mobile settings->version->Android Target version
1)Use the Initialize ReplayKit
block in your first (loading)scene in "when created" Event.
Use this block only once a session. If you want to ask the user to view the video or discard the video select YES, else select NO. If No the video will been viewed automatically after stop recording.
2) EXAMPLE: Create an Actor "Start/Stop Record button"
3)EXAMPLE: In the Events tab of the Actor create an boolean Attribute and set this to true when Actor is created.
4)EXAMPLE: In the Events tab of the actor add an when the mouse is pressed on Self
- Setup the Actor animation like example below.
- Put the Start Recording
block between the if startRecording statement, when startRecording is true then set startRecording to false and switch to animation 1 (stop button) and Start Recoding.
- Put the Stop Recording
in the otherwise block, set the startRecording to true again and switch back to animation 0 (start button) and Stop Recording.
5)EXAMPLE: Create an scene where you want to create the Actor (Start/Stop button). In the Events tab add an when created event.
- Put the replaykit available
block in an if statement and put the create actor between it.ReplayKit works only on iOS9 or above and Android 5.0 or above and because it is not available on all devices, you only want to show the Recording button on devices where the Replaykit is available.
If the ReplayKit is not available it will return false and the Actor will never be created.
6) Test it and play with it. You can share the video when you preview the video. Apple has set an standard share message that cannot be modified.
Standard message when you testing is:[app store app name] from [developer]
This message will be set to your game when you publish your game.
This boolean block turns true when recording start and turns to false when recording stops.