Everyplay Plugin.


I am working on few plugins for android, rewarded video ads from, AdColony, AppLovin, Chartboost, UnityAds, Vungle,a simple Sharing plugin so you can share for example to email your score and link of your application and Everyplay. Everyplay is a service which allows you to share gameplay videos from your game. I will release them all to UE4 community for free once they are all tested
I am using the latest 4.13 preview3 version of the engine.

I am testing Everyplay plugin right now. The plugin seems to be initialized properly, i am getting an event from the sdk but when i am calling a method, application crashes and i am getting an error:

E/AndroidRuntime(31909): java.lang.NoClassDefFoundError: Failed resolution of: Lcom/everyplay/Everyplay/R$layout;

E/AndroidRuntime(31909): at com.everyplay.Everyplay.view.ag.<init>(Unknown Source)

E/AndroidRuntime(31909): at com.everyplay.Everyplay.view.bi.m(Unknown Source)

E/AndroidRuntime(31909): at com.everyplay.Everyplay.view.bi.<init>(Unknown Source)

E/AndroidRuntime(31909): at com.everyplay.Everyplay.view.f.b(Unknown Source)

E/AndroidRuntime(31909): at com.everyplay.Everyplay.view.EveryplaySocialActivity.onCreate(Unknown Source)


E/AndroidRuntime(31909): Caused by: java.lang.ClassNotFoundException: Didn’t find class “com.everyplay.Everyplay.R$layout” on path: DexPathList[zip file “/data/app/com.YourCompany.RisingBirds-1/base.apk”],nativeLibraryDirectories=[/data/app/com.YourCompany.RisingBirds-1/lib/arm, /vendor/lib, /system/lib]]

E/AndroidRuntime(31909): at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)

E/AndroidRuntime(31909): at java.lang.ClassLoader.loadClass(ClassLoader.java:511)

E/AndroidRuntime(31909): at java.lang.ClassLoader.loadClass(ClassLoader.java:469)

E/AndroidRuntime(31909): … 18 more

E/AndroidRuntime(31909): Suppressed: java.lang.ClassNotFoundException: com.everyplay.Everyplay.R$layout

E/AndroidRuntime(31909): at java.lang.Class.classForName(Native Method)

E/AndroidRuntime(31909): at java.lang.BootClassLoader.findClass(ClassLoader.java:781)

E/AndroidRuntime(31909): at java.lang.BootClassLoader.loadClass(ClassLoader.java:841)

E/AndroidRuntime(31909): at java.lang.ClassLoader.loadClass(ClassLoader.java:504)

E/AndroidRuntime(31909): … 19 more

E/AndroidRuntime(31909): Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack available

V/ApplicationPolicy( 927): isApplicationStateBlocked userId 0 pkgname com.YourCompany.RisingBirds

W/ActivityManager( 927): Force finishing activity com.YourCompany.RisingBirds/com.everyplay.Everyplay.view.EveryplaySocialActivity

W/ActivityManager( 927): Force finishing activity com.YourCompany.RisingBirds/com.epicgames.ue4.GameActivity

I have uploaded the APL file and the full logcat.

I have started making the plugins prior to 4.13 version.

I am not sure if i declare correctly the activities, in APL file, for the Androidmanifest, though it seems to write them correctly on APK package or the libraries are linked properly.

The Everyplay sdk is here: https://github.com/Everyplay/everyplay-android-sdk

Any ideas what might causing this error?

I posted a question at answerhub too:https://answers.unrealengine.com/questions/479185/android-everyplay-plugin-runtime-error.html


  • You can download the plugin files(what i have done so far) from the answerhub link above.

There are resource files in the SDK which you also need (the res directory).

Hi Chris,

So i need to add a folder named res in the plugin directory and then copy those resources files from sdk there?

I will add the resource file from the sdk to the build directory with the following line in the APL:

<copyFile src="$S(PluginDir)/…/…/res" dst="$S(BuildDir)/res" />?

I don’t believe that is going to do what you want. You should copy the project directory to JavaLibs in <prebuildCopies> instead. Or, since 4.13 now supports AAR files, you can package it that way and add it as a dependency in the aar-imports.txt (UPL can add to this list; new name for APL).

Hi Chris,

I packaged the sdk, as an aar file.

How do we add it, as a depedency, to the aar-imports.txt, with UPL/APL, when using a project plugin?

Where we could find more info about the new UPL, in 4.13 version?

You can add a new section to your UPL file:

	<insertValue value="repositories $(PluginDir)/../../ThirdParty/repository"/>

Then put your AAR (EveryPlay-1.5.3.aar) in YourPlugin/ThirdParty/respository/com/everyplay/Everyplay/1.5.3 (assuming the build.cs and UPL are in YourPlugin/Source/YourPlugin.

You will also need a EveryPlay-1.5.3.pom in this directory with your packaging and dependencies.

I added the new section to UPL and the aar file in Plugins/Everyplay/ThirdParty/respository/com/everyplay/Everyplay/1.5.3.

I tried to package project and i am getting an error:UnrealBuildTool Exception: System.IO.DirectoryNotFoundException: Could not find a part of the path ‘C:\Program Files (x86)\Epic Games\4.13\Engine\ThirdParty\repository’.

At some point i added the .aar file in a similar folder path in the Engine directory and saw it extracting in to Unreal Projects\RisingBirds\Intermediate\Android\APK,but then i was getting another error about multidex error if i remember correctly.

Anyway i don’t know if it is something wrong in the file structure or because i am missing the .pom file and/or is something wrong with my .aar file.

How do we create the pom file, from Android studio?

By the way, here is the plugin file we everything i have done so far, if anyone wants to give it a try with the aar, pom files and wants to use it in his game:

Forums don’t let me upload the zip file,so i uploaded at answerhub’s question i have posted.

I corrected the missing symbol error. Now i am getting the following message:

AARImports: com.everyplay, Everyplay, 1.5.3

Unable to find package com.everyplay/Everyplay!

I added the following pom file:

<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

But i am still getting the same error.

Remove the dependency on itself; this is redundant and incorrect. The groupId would be com.everyplay, not com.everyplay.Everyplay (the artifactId is appended).

With this pom file:

<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

I am getting the same error.

The aar and pom files are in C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Plugins\Everyplay\ThirdParty\repository\com\everyplay\Everyplay\1.5.3

off topic here, what is the difference between APL and UPL?, the name? I just recompile my plugins for 4.13 and everything work fine, I even don’t know before read this today jaja :stuck_out_tongue: , I figurated new features , where I can see an example of that black magic?

AndroidPluginLanguage (APL) is now UnrealPluginLanguage (UPL) since iOS now shares it. It is just a name change; you don’t have to do anything.

At UnrealEngine/Engine/Source/Programs/UnrealBuildTool/Android/AndroidAARHandler.cs file i saw the error comes up in this method:

public void AddNewAAR(string PackageName, string BaseName, string Version)
			string BasePath = FindPackageFile(PackageName, BaseName, Version);
			if (BasePath == null)
				Log.TraceError("AAR: Unable to find package {0}!", PackageName + "/" + BaseName);

I change the pom file:

<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

The aar and pom files are in C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Plugins\Everyplay\ThirdParty\repository\com\everyplay\Everyplay\1.5.3

Maybe something is wrong in this path or in the:

<insertValue value=“repositories $(PluginDir)/…/…/ThirdParty/repository”/> line?

<insertValue value=“repositories $(PluginDir)/…/…/ThirdParty/repository”/>

should be

<insertValue value=“repository $S(PluginDir)/…/…/ThirdParty/repository”/>

repositories looks for m2repository directories in the path provided and adds them all, and $S(PluginDir) gets replaced in UPL properly, but $(PluginDir) is passed through and isn’t valid since the code that uses it doesn’t know which plugin context it came from.

Yes the repository solved this problem.

Now i am getting the following:
====09-Sep-16 8:51:41 PM====UPDATING BUILD CONFIGURATION FILES====================================================
Updating project.properties, local.properties, and build.xml for downloader_library…
Error: C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Intermediate\Android\APK\JavaLibs\Everyplay-1.5.3 is not a valid project (AndroidManifest.xml not found).
Updating project.properties, local.properties, and build.xml for Everyplay-1.5.3…
Error: C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Intermediate\Android\APK\JavaLibs\Everyplay-1.5.3 is not a valid project (AndroidManifest.xml not found).
Error: No Android Manifest at: C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Intermediate\Android\APK\JavaLibs\Everyplay-1.5.3

I notice that at C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Intermediate\Android\APK\JavaLibs\Everyplay-1.5.3
there is a folder, Everyplay-1.5.3, containing the R file Android manifest, classes.jar, jni folder etc… All these,files/folders, should be extracted in the
C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Intermediate\Android\APK\JavaLibs\Everyplay-1.5.3, right?

The package name in Android manifest within Everyplay-1.5.3.aar should be com.everyplay?

By the way, if i unziped the aar file, changed a value in manifest then zip it again with .aar extension, would it still work, like the aar file produced from android studio, or it might cause problems to packaging?

Package name in the manifest should be the full package name (com.everyplay.Everyplay). All the files in the AAR should be at the root level; not in a directory in the AAR.

The build is successful now, in the Intermediate\Android\APK folder, all folders/files seems to be extracted properly but at the Log file i see this:

UATHelper: Packaging (Android (ETC1)): UnrealBuildTool: Extracting AAR Everyplay-1.5.3
UATHelper: Packaging (Android (ETC1)): UnrealBuildTool: AAR Manifest file C:\Users\Makis\Documents\Unreal Projects\RisingBirds\Intermediate/Android/APK\JavaLibs\Everyplay-1.5.3\AndroidManifest.xml parsing error! System.NullReferenceException: Object reference not set to an instance of an object
UATHelper: Packaging (Android (ETC1)): .
UATHelper: Packaging (Android (ETC1)): UnrealBuildTool: at UnrealBuildTool.AndroidAARHandler.ExtractAARs(String DestinationPath).

I will test it in the weekend if it runs properly on a device.

ExtractAAR tries to read the minSdkVersion from the AndroidManifest.xml so it can create the project.properties file. You should have something like this:

<?xml version="1.0" encoding="utf-8"?>
    <uses-sdk android:minSdkVersion="9"/>

Ok, aar files seems to extracted properly now. I notice that i still need to include the following lines in Everyplay_APL file:

    <copyFile src="$S(PluginDir)/../../lib/Android/" dst="$S(BuildDir)/libs/" />
    <isArch arch="armeabi-v7a">
			<copyFile src="$S(PluginDir)/../../lib/Android//armeabi-v7a/libeveryplay.so" dst="$S(BuildDir)/libs/armeabi-v7a/libeveryplay.so" />-->
    <!--		<isArch arch="armeabi-v7a">
			<copyFile src="$S(EngineDir)/Source/ThirdParty/Oculus/LibOVRMobile/LibOVRMobile_062/VrApi/Libs/Android/armeabi-v7a/libvrapi.so"
						dst="$S(BuildDir)/libs/armeabi-v7a/libvrapi.so" />
		<copyFile src="$S(EngineDir)/Source/ThirdParty/Oculus/LibOVRMobile/LibOVRMobile_062/VrApi/Libs/Android/VrApi.jar"
					dst="$S(BuildDir)/libs/VrApi.jar" />
		<copyFile src="$S(EngineDir)/Source/ThirdParty/Oculus/LibOVRMobile/LibOVRMobile_062/1stParty/VrPlatform/libs/vrplatlib.jar"
					dst="$S(BuildDir)/libs/vrplatlib.jar" />
		<if condition="bRemoveOSIG">
				<deleteFiles filespec="assets/oculussig_*" />


If i don’t the plugin never gets to intiailed,

I don’t get the Everyplay init message during the packaging.

Now regarding the plugin, it sows the Everyplay service menu correctly now, since resources are now included properly.
It seems to record the gameplay, i can see the video being save in a folder in my device and can open it with a video player.

Once, though i try to play the last recording i see a black screen and when tapping the android back button, application crashes.

I am getting this error:

If i try to show the sharing modal of the last video i get a similar error :

I will ask Everyplay support too.

*Regarding the rest of plugins, Unity Ads and AdColony seems to show rewarded videos correctly. AppLovin, Chartboost, Vungle remaining, for testing.
I will make a new thread with all the plugins in Engine Source & Github, and start sharing them and try to have most of them working.

A small update.

I uploaded the plugin with what i have working so far to github:https://github.com/PandoraEntertainment

For now you can only record video not share it. I don’t know if we will get it solved. Everyplay support looks at it too, but so far Unreal seems to not like it when Everyplay meshes with views.

At the same link you can found the rest of the plugins, you can check more at this thread:https://forums.unrealengine.com/showthread.php?127487-FREE-AdColony-AppLovin-Chartboost-UnityAds-Vungle-Sharing-OneSignal-Facebook-Everyplay&p=617273#post617273