Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Integrating Plugins into a Corona Cards app
Started by kausthubram.rajesh Dec 13 2018 06:10 PM

6 replies to this topic
coronacards plugins android

Best Answer richard11 , 13 December 2018 - 11:23 PM

I don't have any experience with Corona Cards myself, but Corona plugins are stored on the Corona build servers. When you compile through the simulator, you're asking the build server to do the compile and it's therefore able to pull in any plugins you're subscribed to. When you build native though, as far as I understand it you're compiling using local tools that don't have access to those build server stored libraries.

I'm wondering though, if you can work around that by just opening something up in the simulator that calls the plugin. This should drop a copy of the appropriate plugin into the Corona cache folder, and you might be able to then copy it directly into your native app so that the local compiler can see it. Does this make sense?

Downside being that you won't receive updates automatically, and there are still some to come with Qiso. You'd need to repeat the above when you want an updated version.

Hope this works!

[TOPIC CONTROLS]
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

kausthubram.rajesh

[GLOBAL: userInfoPane.html]
kausthubram.rajesh
  • Observer

  • 5 posts
  • Corona SDK

Hi, I am trying to integrate the Qiso Isometric Game Engine into my Corona Cards app but it keeps crashing. 

I have successfully got it running on its own but integrating it into the coronaview just isnt working at the moment.

 

I was wondering if it possible to integrate plugins into corona cards and if there is any special way you should go about doing this.

 

EDIT: This is the error I am getting:

 JNI DETECTED ERROR IN APPLICATION: JNI FindClass called with pending exception java.lang.RuntimeException: /Users/jenkins/slaveroot/workspace/CoronaCards/OS/android/platform/resources/init.lua:913: module 'plugin.qisoengine' not found:'



[TOPIC: post.html]
#2

richard11

[GLOBAL: userInfoPane.html]
richard11
  • Contributor

  • 342 posts
  • Corona SDK

  Best Answer

I don't have any experience with Corona Cards myself, but Corona plugins are stored on the Corona build servers. When you compile through the simulator, you're asking the build server to do the compile and it's therefore able to pull in any plugins you're subscribed to. When you build native though, as far as I understand it you're compiling using local tools that don't have access to those build server stored libraries.

I'm wondering though, if you can work around that by just opening something up in the simulator that calls the plugin. This should drop a copy of the appropriate plugin into the Corona cache folder, and you might be able to then copy it directly into your native app so that the local compiler can see it. Does this make sense?

Downside being that you won't receive updates automatically, and there are still some to come with Qiso. You'd need to repeat the above when you want an updated version.

Hope this works!

[TOPIC: post.html]
#3

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,460 posts
  • Enterprise

I don't know how well plugins are designed for CoronaCards. CoronaCards was designed to let you run a Corona view inside an existing native app. But since it's a native process, you could look at the Corona Native documentation and see how to download plugins for Native and include them in your project. For iOS it's a download scheme you can do directly in Xcode. For Android, there is a download script that you run from the command line and then you follow the instructions on putting the jar files in the right place.

 

Rob



[TOPIC: post.html]
#4

kausthubram.rajesh

[GLOBAL: userInfoPane.html]
kausthubram.rajesh
  • Observer

  • 5 posts
  • Corona SDK

Thank you to both answers, yes I finally got it to work. Turns out you were correct, I had to download it and then created a plugin folder in android studio.  I put the files in that plugin folder and in the code I put 

 

local qiso = require "plugin.qisoengine"

 

At the top and it worked.



[TOPIC: post.html]
#5

richard11

[GLOBAL: userInfoPane.html]
richard11
  • Contributor

  • 342 posts
  • Corona SDK

Fantastic.

Out of curiosity, does it seem to be performing well in native? There shouldn't be any difference theoretically, as far a understand it, but again I've no experience with Corona Cards myself. Would be interesting to know it behaves ok.

[TOPIC: post.html]
#6

kausthubram.rajesh

[GLOBAL: userInfoPane.html]
kausthubram.rajesh
  • Observer

  • 5 posts
  • Corona SDK

It seems to be pretty good in Native. Right now I'm just testing loading different simple-ish maps. But the sample you've provided runs well enough, no lag when panning, I'm not sure about character movements and animations but for my project I don't think I'm going to need many of those.

 

Will keep you updated if anything breaks or if performance takes a large hit.



[TOPIC: post.html]
#7

richard11

[GLOBAL: userInfoPane.html]
richard11
  • Contributor

  • 342 posts
  • Corona SDK

Brilliant, thanks.


[topic_controls]
[/topic_controls]

Also tagged with one or more of these keywords: coronacards, plugins, android