COGames's Recent Forum Activity

  • After updating to R257.3 (due to Chrome update), upon exporting to HTML5 Website, I get a message that it was unable to run the script minifier and needs Java 8+ installed (which I already had, but reinstalled anyway making sure to install 64bit as the message instructed). After shutting down, rebooting, and exporting, I still get the message that it didn't minify.

    Any ideas?

  • Same problem here and then found that Chrome did an update affecting sound. I just uploaded the latest beta version of C2 and it works now. Keep in mind that Chrome now requires the user to touch the screen before sound is played

  • I'm looking to make a flash card app, where I keep the sprites (objects) in an array and get them when the cards are cycled through, but I can't see how to do this (since you have to select the object in C2). Is there a way to do this using an array?

  • How do you know you need that? Have you trie changing it to textarea intstead of text. That will let it be multiline

    Thanks! I didn't even realize you can change the type.

  • I know I need CSS, but I'm at a loss.

  • You can use newline as the separator.

    Thanks! It works

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • This is easy if you replace the CRs with commas or another separator, for the tokenat to work. Lets say your imported data is in a string variable "InputString". First you have to replace the CR values with commas and load that into a second variable "CSVstring".

    Use the System replace like this:

    CSVstring = replace(InputString, newline, ",")[/code:1ga6e982]
    
    Then you can parse through CSVstring using tokenat and "," as the separator.
    

    That's what I was trying to avoid. But thanks anyway

  • I'm trying to parse a file list such as:

    apple

    pear

    banana

    I know this would be easy to do with a comma, but this is how all the files I'm using are constructed (and there's over 50 files).

    I tried using the hex codes for CR & LF (0D 0A 2 times) but I got an error: tokenat(file,n,0D0A0D0A)

    tokenat(src, index, separator)

    Return the Nth token from src, splitting the string by separator. For example, tokenat("apples|oranges|bananas", 1, "|") returns oranges.

  • > I want to write and read array to/from localstorage?

    > how to do this?

    >

    To save it just set "LocalStorage -> Set key [key] to [Array.AsJSON]

    to load it fetch the key and set load the array like

    On LocalStorage Item get => Array => Load From JSON [LocalStorage.ItemValue]

    Regards

    Andy

    Hey - thanks for this!!! You just saved me a day of work

  • I'm so confused on sizes of objects. For example, if I make a button, just a box (sprite), and then change it to be a png button, the size of the image I used is limited to the original size of the box sprite that I had. Is there a way to not have this? I've been getting around this by setting the size of the object on start of layout, but I'd love to know what I'm doing wrong.

  • COGames

    Have you tried this? It works for me.

    Yes, and it worked sometimes but not every time (that I could tell).

    I ended up saving the scene when specific objects are dropped and that fixed the save/load problem, and it works fine now.

  • I'm saving a scene in memory every time the user moves an object, by using "on touch end" then save scene. I don't want to do this when one object is touched - is there a way to exclude this object from the "any touch end"? I did try add the condition that the object is "not in touch or touching" but it seems that doesn't work every time.

COGames's avatar

COGames

Member since 20 Dec, 2015

Twitter
COGames has 2 followers

Trophy Case

  • 8-Year Club
  • Forum Contributor Made 100 posts in the forums
  • RTFM Read the fabulous manual
  • Email Verified

Progress

11/44
How to earn trophies