Kraudi's Forum Posts

  • Not sure if this will be helpful, but this is how I added "cordova-plugin-facebook4" plugin to my app for game analytics:

    > Add the following lines to config.xml
    
    <plugin name="cordova-plugin-facebook4" >
    <variable name="APP_ID" value="1234567890" />
    <variable name="APP_NAME" value="App name here" />
    <variable name="FACEBOOK_ANDROID_SDK_VERSION" value="4.40.0" />
    </plugin>
    
    
    Add to config.json in "plugins" section:
    
    {
    	"id": "cordova-plugin-facebook4",
    	"version": null,
    	"variables": [["APP_ID", "1234567890"], ["APP_NAME", "App name here"], ["FACEBOOK_ANDROID_SDK_VERSION", "4.40.0"]]
    },
    
    

    Add files to zip and build with C3. If all done correctly you should be able to call methods from this plugin from scripts or with Browser Execute Javascript action. In my case:

    "facebookConnectPlugin.logEvent('event_name');"

    github.com/EddyVerbruggen/cordova-plugin-taptic-engine

    I tried that with this one as well as I would like to add some sort if vibration to my game.

    After I built the xcode project with the clould service I've seen that the taptic engine plugin was added to the xcode src files.

    I tried to use Browser javascript function to use the function "TapticEngine.strongBoom();" but it does not work. Did I do anything wrong or do I need to do further steps to implement it? Would be nice if you could help on the case if you have some time :)

    Regards,

    Kraudi

  • Yes, but normally that would do nothing, since usually you'd have to actually make some calls to the plugin for it to do anything.

    Yep I tried it with calling the function via javascript with the browser plugin. Doesnt seem to work :(

  • I think the best approach is to use the addon SDK to write a plugin that uses the Cordova plugin. You can also set the Construct addon to automatically add the Cordova plugin as a dependency.

    Okay thanks. Is it also possible to export a cordova project and add the plugin to the xml/json file and then after build it with the construct cloud builder?

  • I would like to know how I can use a third party cordova plugin like this?

    github.com/EddyVerbruggen/cordova-plugin-taptic-engine

    Scirra added it to their build service whitelist but I have no clue how to use it?

    Regards;)

  • The Cordova team is still discussing it. While there is currently a warning for it, this will not prevent you from publishing.

    You can follow their discussion at github.com/apache/cordova-ios/issues/661. They appear to be treating it as a high priority issue, but the problem is complex.

    Alright! Thanks for it :)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Any news on the case? Getting the same from apple.

  • Hello!

    Another problem I have is the share sheet I would like to add on iOS. I used the official share plugin but it doesn't work. When I press the button nothing happens.

    Did I do anything wrong?

    Regards,

    Kraudi

  • You do not have permission to view this post

  • Thank yo uvery much Nepeo

    I'll look into that because that sounds interesting. Hope to figure something out and hope it isn't too complex.

  • Ok I changed some stuff it is definitely more accurate. I did it with 'move 1px forward" you mentioned.

    Heres the v2 demo

    polyth-game.com/builds/snooker2

    Though it's still not good enough because if you play the red ball just thinly the line indicates that you will not hit the ball. Nevertheless the white ball still hits the red ball in the end so that means some calculation is not 'good enough'. Also the shot line sometimes goes the wrong way.

    If you have some minutes would you mind looking into the c3 file itself if I share em?

    Regards and tnx!

  • Thank you very much R0J0hound

    I tried doing it with the loop and it works but it's very inacurate. DOn't know If I've made some mistake but you can have a look in the demo here.

    polyth-game.com/builds/snooker

    (You can move red balls with pressed right mouse)

    Also this is the code I've made.

    i.imgur.com/WOWk561.png

    I've also added more collision points to the red balls so it is more accurate but doesn't changed much.

  • I think this thread would help me a lot if the image there is still online

    construct.net/en/forum/construct-2/how-do-i-18/detect-collision-point-balls-84860

    I think this is what I need to get the coordinate of the impact between the 2 balls so I can calculate the angle of motion.

  • Hey guys.

    I can't get it together.

    This is how my game currently looks

    i.imgur.com/oR2SjIE.png

    What I wanted to do is show a projected line for the red ball (white short line). So If change the angle the line should show the direction the red ball goes to. I thought it would be easy but I just don't know how to do it.

    I think something like calculate the angle the balls are hitting each other to calculate their direction?

    Ignore the green line, its just to check collision with any red ball.

    Would be nice if someone has an idea which I could may understand :D

    Regards,

    Kraudi

  • Thank you! Looks like I have just missed some stuff :D

    Btw is there any alternative to rex_moveTo using the current runtime?