retrodude's Recent Forum Activity

  • Aphrodite

    Can the execute javascript command use system function expressions from C2? I tried creating a function called "p" which set's the sprite objects opacity to 100 when called. I also created a function called"q" which sets the objects opacity to 0.

    But when I tried doing

    Browser.Execute javascript "fgl.inApp.initiateUnlockFunction(function(){"&functon.call("p")&"},function(){""&functon.call("q")&"});"

    It doesn't work. I don't even think it can be used this way, can it?

  • Try Construct 3

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

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

    How were you able to get premium to work? That's the one feature I'm unable to get running for the fgl sdk. Did you use the execute javascript command? If so could you send me maybe a screenshot or just explain how you got it working either through here or pm?

    I have the function being called to open the menu but I'm unable to unlock the feature during gameplay after pressing a button. I think I'm missing a function that updates the menu. I wanted to include one in the fgl sdk but were not suppose to edit it.

  • I appreciate the input. But I read that there's some compatibility issues with that command. It doesn't seem to work on all devices. I guess i'll find a workaround then.

  • You can still access global variables using the execute javascript command in construct2. I'm wondering how I can directly change the value of the global variable using the javascript browser command in the events.

  • RuneS

    jabelone

    Are you using cocoonjs for compilation? If so then it won't work. Maybe with phonegap it might.

    Edit:

    I just realized this is an old post......................

    jabelone

    Please refrain from posting on old threads that are irrelevant and somewhat dead.

  • The links posted by Kyatric will definitely be useful. You could also do some searches around the forum. You may just come across some useful information.

    noless

    I'll try explaining it to you in basic logic.

    If you plan to do just one "Best Score" for the user then you probably don't need arrays. Unless you want a leaderboard? Which I'm assuming you don't.

    You should use webstorage to store the value. Webstorage will remove the stored value if you clear you cache (I believe this is how it works). So its good for storing or saving values.

    Event>Action

    webstoreage>setlocalvalue will let you store the required value into a "key".

    you can then load value from the key to a global variable.

    For example:

    global variable num = 5;

    webstoreage set localkey "getval" to num;

    ->You now have the localkey "getval" which has stored in the value 5 from num.

    You can then load the key, and set num to this key by using a command like this:

    Set num towebstorage.localvalue("getval");

    num is now equal to the stored value in the key.

  • Is it possible to change the value in the global variable using the execute JavaScript action? I'm trying to integrate fgl's sdk and I'm having issues with integrating their premium feature.

    Here's what I have tried so far in pseudo-code:

    global variable number premium = 0;

    Following this format-->Event>Action

    OnTouched premiumButton > Browser.Execute javascript "fgl.inApp.initiateUnlockFunction(function(){"&premium=1&"},function(){"&premium=2&"});"

    Problem:

    This doesn't seem to change the global variable in Construct2 when the function call is made. It does initially make the call and create the menu to accept or cancel it but once again it doesn't change the variable when the function is called. Is there another way to accomplish this?

    Such as declaring a variable within the execute javascript command?

  • fldr

    I think its an issue from fgl (the ad part). I'm also having problems getting the ads to close on chrome although it strangely works on opera and firefox (tested on android). From what I can gather, branding seems to work. I'm still having issues getting the scoreboard to work mainly because I'm not sure what scoreboard we use. Is it gamersafe scoreboard that we need to submit scores?

    tumira

    Whoops, I foregot to edit my post, I read that on the fgl forums but fore-got to update my post.

  • Does anyone know what fgl means by pause/resume? I just read there implementation sdk pdf file as well as there sdk documentation and it says nothing about pausing or resuming in their sdk. So how do we integrate it? I even went through there fgl.js file and there's no function call or anything that is remotely close. Or is it just regular pause and resume from construct2?

    Also apparently if you want the tier 3 prize of 200$ you need to have achievements working. Which isn't even supportive in the v1.2 of fgl's sdk. So I guess I might use the previous sdk then.

    I'd rather not wait for the plugin, I think I'll just try normal means to implement the sdk.

  • his master who

  • I'm having a similar black screen issue as DARTH Crusher on my samsung galaxy nexus. After ludei loading screen I'm stuck at a black screen with a rocket floating, and that's about it.

  • It would be good practice, but flappy bird is pretty much a template now. Which really ruins the fun of learning the algorithm which would probably benefit the c2 user and allow them to make their own personal flappy bird game unique.

    But nonetheless I have come across some good examples of clones for flappy bird that have flattering artwork to go with it or additional features like shops, which doesn't directly cut and paste from the template created by Tom.

retrodude's avatar

retrodude

Member since 11 Oct, 2012

None one is following retrodude yet!

Trophy Case

  • 12-Year Club
  • Email Verified

Progress

13/44
How to earn trophies