AndreasR's Forum Posts

  • Hi,

    I personally recommend a 16:10 resolution, for instance 1280x800. This fits best on most devices.

    Then use Scale Outer.

    After that, you can use CocoonIO in order to build your C2 project to Android/iOS. You can find a guide here.

    https://shatter-box.com/knowledgebase/cocoonio/

    If you want to use GameCenter, you can download the free plugin CoconGameCenter mady by ludei for CocoonIO.

    https://shatter-box.com/knowledgebase/c ... he-plugins

    Moreover if you are new to build iOS apps, you maybe find this guide useful.

    https://shatter-box.com/knowledgebase/p ... tunes-ios/

    https://shatter-box.com/knowledgebase/i ... -products/

    https://shatter-box.com/article-categories/gamecenter/

    Regards

    Andy

  • Savvy001

    Firebase Analytics does not have web (javascript) api, it only provides iOS and andriod api. Sorry I could not support this feature.

    Hopefully ludei will make such a plugin

    Regards

    Andy

  • rexrainbow

    METR1C

    I just tested it on WebView+ and got this error message.

    [quote:1zwexhd3]This operation is not supported in the environment this application is running on. "location.protocol" must be htttp or https.

    Regards

    Andy

  • AndreasR

    rexrainbow

    Hi Andy,

    I am not getting a message when i hit the Fb button. Nothing at all happens when i tap on it yet in Chrome it works perfectly. Im building it on Cocoon as WebView+ Ive attached a screen shot of the code, any ideas?

    post a picture

    Hi,

    I'll make a test on my end.

    But it seems your Firebase plugin is outdated. Mine shows the new firebase logo as icon.

    Can you update it and try again?

    You can download them here

    https://shatter-box.com/knowledgebase/f ... quirements

    Regards

    Andy

  • AndreasR

    Awesome, will do. In work atm so will try again when home. Thank you very much Andy

    Sure, you're welcome as always

    Let me know once you have got new information.

    I'll work on my Firebase Template, I'll keep you posted once it's done.

    Regards

    Andy

  • AndreasR

    Hi Andy, i am not getting any error. Basically you click on the facebook button to login and nothing at all happens Works fine in Chrome/Firefox ect.

    Yes you only see the error if you log it. Canvas+ lets access you the error log in the developer app. That doesn't apply to the Webview engines.

    So just use a text object and add following actions.

    "Authenticaction - On login error - Set text to "Authenticaction.ErrorMessage"

    Then tell us the error you got.

    Regards

    Andy

  • > METR1C

    >

    > According to AndreasR said,

    > [quote:hv0vwdi5]It should work for WebView(+) on CocoonIO and Intel XDK (install the inapp browser plugin), however it will not work with CocoonIO's canvas+ engine due to the fact that Canvas+ do not support websockets.

    >

    rexrainbow

    AndreasR

    Thanks for the reply Rex, and once again thanks to Andreas who has helped me before with other issues. But WebView+ isnt allowing the Auth popup to login. Is there any other way around the issue? Or a sample capX that shows this working on mobile?

    Thanks guys

    METR1C

    You must add the domain to the OAuth Redirection list first. Otherwise you'll get this error.

    Find out more here:

    https://shatter-box.com/knowledgebase/f ... edirection

    I'm not sure what the domain of the Intel XDK/CocoonIO build is, but I guess it's the bundle id. So try to add your Bundle ID to the OAuth Redirection list.

    Regards

    Andy

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hello man, could you please add my game "Light the candle - Construct 2 game" to the collection?

    Link: https://play.google.com/store/apps/deta ... ecandle.gt

    Thanks a lot !!

    Chucky

    Sure, game has been added to the list <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    Regards

    Andy

  • AndreasR

    Thanks , I will put them in this page, and the document page of related plugins.

    You could also provide the product link in the (scirra) store, too.

    rexrainbow

    thank you! Here is the first link of the docs. It will be extended.

    https://shatter-box.com/knowledgebase/f ... ct-2-game/

    I'll send you the link to the capx examples once I'm done with them.

    Thank you!

    P.S. I hope it's fine that I linked to your plugins, if not let me know.

    Regards

    Andy

  • AndreasR

    There are 2 possible plugins for saving items of users in firebase -

    1. rex_firebase_itemtable which address a value by ( itemID, propertyName).

    [itemID]

    ----[propertyName] - value

    In your case, it will be ( userID, itemName ), for example ( userID, "coin" ) = 1000

    2. rex_firebase_itembook which address a value by ( tableID, itemID, propertyName )

  • LOl

    ----[itemID]

    --------[propertyName] - value

    It support updating multiple tables in a writing access (atomicity).

  • rexrainbow

    Thank you for the links. I'll built an example for those plugins as well.

    I'm also writing a tutorial for it then.

    Feel free to link it on your website (I'll send you the links once I'm done).

    Regards

    Andy

  • AndreasR

    Use "Expression:DisplayName", "Expression:PhotoURL" to get display name or photo url from google account / facebook account. (sample capx) In email - password login, call "Update profile" to set these values.

    Inventory... I would like to use rex_firebase_itembook plugin to implement that. But it might be too complex for a simple use case.

    Thanks for sharing this template!

    It actually fetches the user image. But it gets blocked by Scirra Acarde. I'll add the Display Name with an upcoming update, thanks for that hint

    Moreover I'll add more handlers (facebook and so on)

    [quote:1i18vt07]Image from origin 'https://shatter-box.com' has been blocked from loading by Cross-Origin Resource Sharing policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://games.scirra.net' is therefore not allowed access.

    I haven't used your Inventory Plugin yet. I'll check it

    Thank you!

    Regards

    Andy

  • I made a Firebase Template for Syncing Account Date (Coins, Inventory).

    https://www.scirra.com/arcade/tutorial- ... count-9616

    This is currently in beta, so if you found any bugs or have any suggestions, just let me know.

    Once the code is working perfectly, I'll release the source code of the asset on scirra.

    Please note

    Scirra Acarde is blocking the Google login. Please use the mail login instead.

    Thank you!

  • AndreasR

    I can't release my game because i need firebase and canvas+. Webview+ has poor optimization. I hope they'll make it soon.

    Hi,

    I'm not sure if ludei makes a Firebase Plugin for Construct 2 working with Canvas+, we just can hope and pray

    We will see what time brings. But if your game just waits for the release of the firebase plugin, I personally would recommend you to switch either to WebView+ or to release the game without the firebase feature at the moment.

    Then, if (and it's a big if) Ludei decidces to make such a plugin, to add those features with an update.

    Regards

    Andy

  • newt

    I did not try to use intel XDK or cocoon.io for my plugins, sorry I have no idea.

    You might check this post

    [quote:q16ye2an]you have to add "In App Browser Plugin" to make it work. You may find "In App Browser Plugin" from Cranberrygames's work.

    It should work for WebView(+) on CocoonIO and Intel XDK (install the inapp browser plugin), however it will not work with CocoonIO's canvas+ engine due to the fact that Canvas+ do not support SSL Websockets.

    Hopefully Ludei will make a Firebase Plugin for Construct 2

    Regards

    Andy

  • Most value evaluating conditions pair up with expressions.

    There is the condition Sprite > Compare X and its pairing expression Sprite.X.

    So, u can use Sprite > Compare X .. or System > Compare two values (using Sprite.X).

    The first one will filter the picklist (SOL), de second one will not filter the picklist.

    There is a reason why i started like this.

    Because in the same logic ....

    You have the condition System > Pick nth Instance and its pairing expression sprite(nth).xxxxx

    'nth' is in fact the IID for an instance of an object in a certain picklist (SOL), it is a zero based index, and it is a number.

    If you have all instances of an object picked, this IID represents also the order that they are created.

    And now some more background info.

    Some conditions (but also expressions) have only a meaning when used with a certain condition.

    The condition 'pick nth instance' has no meaning without a condition that actual picks items (make a SOL), so sprite(nth).xxxxx has no meaning without a pick.

    The expresssion loopindex("i") has not meaning without a loop condition.

    The expression array.curX has no meaning without a 'for each element' condition.

    So, for you to adress an nth instance by instance(nth).xxxx, you should use a 'pick all' (althaught for only 1 line of code as in your example this is redunctant).

    Then using the expression goes like this ...

    "Email: " & input(0).Text & " / Password: " & input(1).Text

    Beeing 0 the IDD of the first instance of the sprite input, 1 the IDD of the second sprite input.

    You can use logical expressions. Like :

    input.InputType = "Email" ? 1 : 0

    But it is a bit weird to use this to return an IID.

    Hi 99Instances2Go

    Thank you very much for your detailed respone.

    I know that I easily can get it via it's IID. But the game generates input fields depending on the current form (register or login). So I wanted to pick the corresponding input field depending on its instance variable.

    So I thought I could pick an instance by the value of an instance variable of it.

    Now I altered my code to this.

    "Email: " & input(input.InputType = "Email" ? input.IID : -1).Text & " / Password: " & input(input.InputType = "Password" ? input.IID : -1).Text[/code:pzbwid6f]
    
    This worked out for me  Thank you for your help!
    
    Regards
    Andy