twg's Forum Posts

  • I have some global variables that I save in Webstorage for sound toggles, initial value of the variables are set to 0(on)and can be changed to 1(off) with an On Touch event. When I test in browser & CocoonJS launcher everything works correctly, but when I export the game and compile an APK with CocoonJS and the game is installed on a device, the 1st time the game is ran the variables are set at 1 for some reason, if I check the options toggles and turn them on setting them back to 0(on) the settings stay fine from then on when you reopen the game, but it's just that first install the variables are set to 1 so the sound if off by default. I triple checked the variables, they always start at 0 and they can only be changed with an on touch event that is on a completely different screen, not sure what is happening here.

  • Ok well nevermind this, I got everything working by making a FB app and using that instead of this sharer and was able to call as many variables as I want without the need for the php.

  • Aren't you missing a "&" in your URL string between both parameters?

    The final string should be

    https://www.facebook.com/sharer/sharer. ... /share.php? score=1000:0&level=3:1

    for example. You need to put the "&" before level, like so:

    "https://www.facebook.com/sharer/sharer.php?u=http://www.mysite.com/share.php?score=" & highscore & ":" & random(1,0) & "&level=" & levelsCompleted & ":" & random(1,0)

    Also, you should use a larger random range (like 1 to 10). The whole point of using the random function there is to make sure that facebook gets a new URL every time and doesn't use the cache

    Just gave this a try and it didn't work, only the 1st variable shows up in the FB post, the 2nd variable is still blank. It's like I'm not targeting the 2nd variable right in the syntax in C2 for it to be able to get read by the GET in the php. I've tried the way you suggested "&level=" & levelsCompleted, tried it with just "level=" & levelsCompleted and nothing works, there has to be a way to get this to work.

    Also the (1,0) was actually a typo, I am using (1, 10).

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • This may not work but it's probably worth a go. Try putting the url into a string variable first and then open the browser object with that variable in a subsequent event.

    I have no experience with php so can't help on the rest I'm afraid.

    Tried the string but couldn't get it working with the php.

  • Bump, really stuck on this, can't figure it out.

  • Followed 's tutorial for a Facebook share button, and got it working fine to show a highscore variable on Facebook, I'm trying to display 2 variables in the Facebook post, highscore and the level they were on and just can't get it working. In my .php file I have

    <?php

    $score = $_GET["score"];

    $scorex = explode(":", $score);

    $highscore = $scorex[0];

    $level = $_GET["level"];

    $levelx = explode(":", $level);

    $levelsCompleted = $levelx[0];

    ?>

    <html>

    <head>

    <title>Site Name</title>

    <meta property="og:title" content="I got <?echo $highscore;?> on Level <?echo $levelsCompleted;?> in this game!"/>

    <meta property="og:image" content="http://mywebsite.com/game.png"/>

    <meta property="og:site_name" content="Game Title"/>

    <meta property="og:description" content="I got <?echo $highscore;?> on Level <?echo $levelsCompleted;?> in this game!"/>

    </head>

    <body>

    <meta http-equiv="refresh" content="0;URL=http://www.mysite.com" />

    </body>

    </html>

    Then I have this code on my on touch event/browser event

    "https://www.facebook.com/sharer/sharer.php?u=http://www.mysite.com/share.php? score="& highscore & ":" & random(1,0) & "level="& levelsCompleted & ":" & random(1,0)

    The highscore works fine but I can't get the levels to show up, not sure if it's the .php or my browser event is wrong. Any help would be appreciated, thanks.

  • Well the levels for Circuit Dash are finally done! We ran into a few minor technical difficulties and one major one being the scaling for 4:3 devices(Damn you iPad, jk we love you.), basically we had to rescale the entire game and redesign the 40 levels that were already done before finishing the last 10 levels, it was a pain in the ass, but nothing about 60 hours of work in 5 days couldn’t fix.

    There are 50 levels total and with the 4 levels of difficulty it should be fun and challenging(or rage inducing, see pic above) for players of all skill levels.

    There is still a lot of work to be done with the leaderboards, play testing across multiple devices, polish etc, but everything looks to be on schedule for releasing this month, assuming the submission process goes smooth, we are hoping to have it on the App Store, Play Store and Amazon by the end of the month, we will announce the exact date in the coming weeks.

    We’ll leave you with a couple screenshots from some of the new levels.

    Again you can follow the game here or at IndieDB http://www.indiedb.com/games/circuit-dash on Twitter https://twitter.com/Patrick_NoD or our website http://nothingordouble.com

    Peace out yall.

  • I'm using an Arial bold font text to display variables in a project, whenever the text is rendered in browser or in CocoonJS launcher the quality of the text is coming out very low quality with a jagged almost pixelated look. What could be causing this or is there a fix?

  • Looks kinda interesting. I like the minimalistic design:)

    When can we play it?

    Thanks, should be out in app stores within the next month, might release a html 5 demo you can play with keyboard not sure yet.

  • Circuit Dash is a fasted paced arcade game with minimalist graphics that tests your speed and reflexes. Turn off the colored buttons to navigate the charge past the circuits and to the end of the level. It has 50 levels with extra level packs coming out in the future, 2 different game modes, normal mode with unlimited lives and saved progress, then you only live once mode with 1 life and no saved progress, leader boards and social media integration. Here are some screen shots.

    Been working on the game for about a month now, the coding, menus, soundtrack are done, just finishing up the sound effects and levels which are about 65% done. The game will be available free on iOS, Android and possibly Windows phone, hoping to release within the next month. I'll keep this updated, but you can also follow at IndieDB http://www.indiedb.com/games/circuit-dash on Twitter https://twitter.com/Patrick_NoD or our website http://nothingordouble.com

  • Hello guys I'm new here on the forum and seek experience and learning, so I have the following questions:

    I have 2 layout, the first has 4 buttons (each 1 means background), the user must choose only one button, thus changing the background chosen.

    Chosen the background the user moves to the next layout (hence arises the doubt), how can I get the background that was chosen in 1 layout and stay with him in the second layout?

    Thanks in advance to all who try to help.

    Ron Sueliton

    Really easy to do with variables, for example you make a global variable called background and set it to 0. Then on each one of your button presses set the variable to a different number, button1 press set global variable to 1, button2 press set global variable to 2 etc.... Then on your second layout you just check what the variable is, on start layout>if global variable background =1 set background to background 1 and so on.

  • Set the Initial State of the Particle emitter to Disabled. Then OnCollision with that ballThing, Move the Particle emitter to Player.X/Y and set Particle emitter to Enabled.

    I just recreated the particles with the name deathExplosion2 and gave it the exact same events and it started working again? Something weird going on here, I have had this happen to a few projects where I don't even touch them for days and come back and something is not working and if I just recreate the object with the exact same events then it works again, this must be some kind of bug, not sure whats going on here.

    Also the way you suggested you said set the emiiter to Disabled, I see no option in properties to toggle the state of the emitter, do you mean change say the Rate to 0 then set it on collision?

  • I have an instance of the deathExplosion off to the left of the layout, then when I spawn a new one on the player it spawns with completely wrong settings, its like the default particle settings. No matter what I change in the particle properties, size, speed, spray type it only effects the instance I have off to the left of the layout, all new particle objects that I spawn don't have the correct properties, I changed the spray type to continuous and the object off the layout sprays continuous but the one I spawn is still single shot, none of the properties effect the particle object I spawn at all.

  • I have a particle object that spawns when I player dies, there is an instance of the object off the layout screen and when a player dies I spawn the particle object on player.x player.y, but when it spawns the particle object it doesn't spawn with the correct settings that I have specified in the particle property window for the object, in fact any settings I change in the particle properties window don't effect the spawned particles at all, it only changes the properties of the particle object I have off to the side of the layout view. Any advice?

  • Im using webstorage to store variables for the toggles in the options menu and when I run the game in CocoonJS launcher I get a Javascript error that says "SyntaxError: Unexpected token ILLEGAL Webstorage_common.jsm line (col undefined). This is either a bug in Construct 2 or a problem in a third party plugin or behavior - please report it to the developer." After I click ok on the error and test the game the webstorage works correctly storing and loading my variables just fine. Why am I getting a javascript error yet it is still working correctly?