No, Windows. I haven’t run any setup though… Did I skip a major step?
No, you’re good. But Windows explains differences between my and your experience.
Also seeing “warning: CoronaBuilder: Splash Screen Control plugin not found” during the build phase, which I’ve been disregarding since I’m not trying to replace the splash… is it that Corona Native requires purchasing this plugin? We’ll actually be doing so anyway towards the end of building this particular project, as it’s for a client, but since it’s an annual fee we wanted to hold out until we’re ready for release!
It seems that splash screen is broken on windows.
Bummer, but at least I’m not doing something wrong!
I’ve put together a tutorial that concatenates everything I’ve read / figured out to get to this stage, as it didn’t seem like anything existed as a single, concise piece. Since everything seems to work and I now know that the splash error is a bug with the current builds, I’ll tidy this up and post a link here tomorrow. Hope it’s useful to others, and thanks for your help in getting there.
Any idea when the splash will be fixed please?
Here’s the tutorial! https://www.qweb.co.uk/blog/creating-a-corona-native-plugin-with-android-studio
Good job! Well look at splash screen issue Monday.
Great, thanks.
Just wondering if there’s been any joy with this yet? Not sure what timezone you’re in…
Hi Richard,
We got an engineer to look into it. Hope there is nothing serious and will be fixed soon.
Brilliant! =)
Hello! So we spent quite a bit of time trying to figure out what is going on just to realize it’s some weird Windows Android Studio bug.
Basically if you press run/debug it won’t copy some resources, including splash screen.
Try selecting “assembleRelease” from gradle panel, then locate an APK in app/build/outputs/apk and install it manually on device. Tell me if this is working.
Meanwhile we’re trying to understand what’s the matter.
EDIT:
It seems that disabling Instant Run solves the issue.
Excellent, thanks. I’ll try this asap and report back.
Seems Android Studio is pretty unstable at the moment
Yep, disabling Instant Run does the trick perfectly! Thanks. Time for me to get properly stuck in to native plugin dev I guess…
I might be getting somewhere with this now (and I might throw together a tutorial to post back here if I am), but I can’t seem to build the jar file from within Android Studio - I’m just getting this when I try:
“JUnit version 3.8 or later expected”
Using the template that came with Corona SDK so presumably this should just work… Any pointers please?
Ah - I think that was because the run configuration wasn’t set to “app”. Skipped over this error now.
I don’t appear to be getting a .jar file when building though. In the build log, under the “Run tasks” section, there’s an amber icon with greyed out vertical lines overlaying it next to the “:plugin:exportPluginJar” task… Presumably that’s important…
Hello! You almost figured it out, good job!
Unfortunately plugin:exportPluginJar got broken with latest update of the Android Studio. You still can do it manually.
Launch “assembleRelease” task, after this go to plugin/build/outputs/aar/plugin-release/. Unzip plugin-release.aar (open it with unarchiver/7z/archieve utility). Inside a folder you’ll see plugin.jar. This is your plugin. Rename it to match your plugin name and you’re good.
Brilliant, thanks. I’m not at my computer at the moment but I’ll see if this works in the morning!
How do I manually launch tasks though?
OK, past that stage now - Tasks can be executed directly from the Gradle tab on the right, if anybody else stumbles onto this thread.
I have my .jar file now, and if I’ve done everything correctly it should contain a couple of simple methods waiting to be called - yay.
Seems I haven’t understood how to use this in a Lua project though. I expected I’d just copy it into a Lua project and require it like any other module, but this doesn’t work. What am I missing?
This is where things are getting complicated. You can not run a plugin like that. For now you have several options:
-
Package a plugin and submit it to marketplace. For that you’ll have to write a little documentation on how to use your plugin and why it’s useful
-
Package your app as Native app, then you don’t have to export a plugin - you’ll have to integrate rest of the plugins into you Android Studio project
-
Get Self-Hosted subscription which allows you to side-load plugins into simulator builds.
This way you can choose to support Corona’s ecosystem, Corona directly, or do it yourself. If you have more questions you can PM me or write here.