CocoonJS plugin updates

0 favourites
From the Asset Store
Fantasy Game includes more than 600 sound effects inspired by hit computer games like World of Warcraft and Diablo.
  • ludei

    One other question: how do we show 'test' ads with the ATP Ads plug? Really not a good idea to be displaying real ads on a dev version.

  • >

    >

    > Remove the whitelist plugin. You are using Canvas+ . It is not necessary there but if you create a project, it is added by default.

    >

    Sorry ludei, removed whitelist plugin and get new error:

    With "www" folder:

    Without www folder:

    Trying Webview+ and the zip without www folder, loads ok.

    Did you use the box2d web physics?

    ludei

    Suggestion: Make a thread about the C2 Atomic plugs and post it in this forum:

    Would make it a lot easier to find them, because google is of limited use (all it wants to show is the old cocoonJS omni-plugin).

    Thank you for the suggestion. In any case, the link to the plugins is on my signature . Just under the picture.

    ludei

    One other question: how do we show 'test' ads with the ATP Ads plug? Really not a good idea to be displaying real ads on a dev version.

    Which ad network?

  • Yes, im using box2d.web

  • Then, please, post the issue in our forums and provide the test case, because we didn't encounter that problem when testing.

    https://forums.cocoon.io/c/problems-troubleshooting

    Regards

  • ludei

    Using AdMob.

    Also, the ATP Ads plug makes C2 projects crash on preview, or any platform that is not Cocoon. This is because plug references the Cocoon.Ad object without testing if it exists. I patched the plug by adding this code to the 'instanceProto.OnCreate' function:

    			
    //Don't run if not on correct platform, or if cocoon undefined
    if (!(this.runtime.isAndroid || this.runtime.isiOS))
    return;
    if (typeof Cocoon == 'undefined')
    return;[/code:36bujtdb]
  • Thank you for the suggestion. In any case, the link to the plugins is on my signature . Just under the picture.

    Just FYI, in FF/Chrome your sig image is so big that the div has to be scrolled to see the ATP link...might want to shrink the sig image a bit.

  • ludei, the project test that im trying to compile is one with 2 simple sprites with physics. I dont know what is happening.

    I also have tried to compile the pinball capx of BasicTribe but again the same problem, black screen in normal compile, and in developer the same error of last screens ive posted.

    I dont know what im doing wrong. I have exported BasicTribe capx with cordova without touching nothing, exactly as it downloads, edited c2runtime.js to add the fix for 1/4 screen, then in cocoon i have created new project from zero. Selected fullscreen, landscape, and canvas+ for android. Deleted whitelist plugin, save changes on all sections and compile.

    Here are the apk. developer app, and zip. I think is my mistake but i cant find it.

    Developer app: https://www.dropbox.com/s/8yytdnoyjyrnzhi/android-armv7-debugDEVAPP.apk?dl=0

    Zip: https://www.dropbox.com/s/2rg1v5co3duncrw/basictribezip.zip?dl=0

    Normal apk: https://www.dropbox.com/s/wuhm5hga2hfyhmo/android-armv7-debugNORMAL.apk?dl=0

  • ludei

    EDIT: Tried with a zip file, and everything is working. Must be a prob with wifi preview. I did have to structure the zip differently than for the cloud compiler; see the post after this one.

    Tried the dev app today...and ran into a pretty bad bug.

    C2's "On Layout Start" trigger doesn't ever seem to fire in the dev app, even though normal exports work fine. This basically make the dev app useless ATM, since any logic under that trigger won't fire.

    This happens in Canvas+ AND Webview+.

    Any idea what could be amiss here?

  • For those who are wondering, here's how to format and zip your exported project so it will run in the cocoon.io dev app. The file structure recognized by the cloud compiler won't work:

      1. Export from C2, make sure minify is disabled. Atomic plugs don't play nice with it yet. 2. Delete the 'config.xml' file in the resultant folder. 3. Zip up the contents of the export folder, not the folder itself. If you do it right, 'index.html' will be in the root dir of the zip file. 4. Put the zip on your device, open dev app, go to the 'Documents' tab, navigate to the file and select it. Three buttons will pop up at the bottom of the screen: 'Canvas+', 'Webview+', and 'Webview'. Select your preferred environment, and away you go.
  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hello!

    I need to add padding on top of that my game was in the center. Canvas + does not support letterbox scale.

    What do I need to add code to appear on top of padding?

  • Hello,

    			
    //Don't run if not on correct platform, or if cocoon undefined
    if (!(this.runtime.isAndroid || this.runtime.isiOS))
    return;
    if (typeof Cocoon == 'undefined')
    return;[/code:wh3grihk]
    

    We updated all the plugins to include the code. Thanks for the hint.

    If you do it right, 'index.html' and 'config.xml' will be in the root dir of the zip file.

    The index.html is the important part. The config.xml is not important when running your source code in the dev-app, because all the plugins are installed at the cloud.

    Mamajuano please, post it in our forums, so all the support team will be aware of the issue.

    Regards

  • ludei

    Modded export instructions to omit config.xml.

    More importantly:

    In my testing ATP Ads, running the AdMob network, is not running in test mode. It is displaying real ads.

    I know it sounds trivial, but people have gotten in big trouble for clicking their own ads before, even if it was only a couple times. No ad plugin should lack the ability to run in test mode if the network supports it.

    tl;dr: This needs to be fixed ASAP.

  • ludei

    now every thing is working fine except 3 problems:-

    1- no sounds! i added media plugin in plugin section and tried older versions.

    2- exit (close browser) action doesn't work, using in app browser default plugin.

    3- i can't find this code to replace in C2runtime.js "this.isRetina = ((!this.isDomFree || this.isEjecta) && this.useHighDpi && !this.isAndroidStockBrowser);"

    so for now I'm exporting as Canvas (webgl: off), if i turn webgl: on i get scaling problem.

  • Egyptoon

    1. Canvas+ does not support WebAudio features (filters, positional audio, fft analysis), and occasionally the triggering latency seems to get really bad for me (hasn't done it in awhile though). Other than this, I've never had any issues with sounds.

    2. Get the Canvas+ plugin and use it's built in 'close app' function. Plugin repo is linked in ludei's sig, but here: https://github.com/CocoonIO/cocoon-plugins-c2

    3. First, if you aren't using notepad++...start using notepad++. <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    https://notepad-plus-plus.org/

    It's around line 434. Make sure you have 'isCocoonJS', not 'IsCocoonJS'...that typo wasted a whole day of my time recently. <img src="{SMILIES_PATH}/icon_razz.gif" alt=":P" title="Razz">

  • TiAm

    Thanks alot my dear friend,

    But I've no sound at all what can i do ?

    it never happened with old cocoonjs.

Jump to:
Active Users
There are 2 visitors browsing this topic (0 users and 2 guests)