dop2000's Recent Forum Activity

  • Oof..

    I would suggest parsing the entire works of Shakespeare into a list of unique words first. This task itself is going to be tricky. You need to remove all punctuation, line breaks and other non-letter characters, replace them with spaces. Then extract every word using tokencount/tokenat. I suggest writing these words to a dictionary as keys, this is the easiest way to get rid of duplicates.

    Then you can start generating that continuous string, and after adding each letter loop through all dictionary keys and check if the string contain such key.

    For Each key in Dictionary
    find(LongString, Dictionary.currentKey)>=0
    ... // word found!
    ... Dictionary delete Dictionary.currentKey
    

    You'll need to use expressions like tokenat, tokencount, find, trim, replace etc. See this link:

    construct.net/en/make-games/manuals/construct-3/system-reference/system-expressions

    Oh, and the string doesn't need to be endless. If no words were found, you can safely trim the string, leaving only the last 20 or so characters. This should help with the performance.

  • I think it should be something like this. But it won't work in preview, you'll have to export it to NWJS to test.

  • What do you mean by "directly" - without prompting the user? You can only do this in NWJS export. Use NWJS action Write Binary File. I guess you'll have to load CanvasSnapshot into the BinaryData object first.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • See this demo:

    howtoconstructdemos.com/chess-game

    Note, it's for two human players, it doesn't have an AI.

  • 1StepCloser Whoa, I'm guessing you are starting to push the limits of Construct. That's why you still have lags even after garbage collection. I suspect the number of object types is the main factor.

    Our project is much smaller: about 50MB in size, 10K events, 500 object types.

    Looks like we might have to condition ourselves to "F12 + Click Collect garbage icon", just as we've conditioned ourselves to "Ctrl + S".

    I now keep DevTools constantly open on a second screen, together with C3 Search window.

  • Again, without any WAIT actions, would this be correct, or would "Change SOMETHING ELSE into ONE MORE THING" still take place before the sub-event "Create SOMETHING ELSE" and thus fail?

    I Construct, both SOMETHING and SOMETHING ELSE will be created before the second top-level event. (if there are no waits)

    Yeah, Construct logic is a bit different from other languages, it takes time to get used to it. One of the most important concepts in Construct is picking. Once you understand how it works, it all starts to make sense!

  • If you export to NWjs, you can use NWJS.ArgumentCount and NWJS.ArgumentAt(n) expressions.

  • I was going to suggest using families. I don't think there is a better solution possible.

  • Ashley Every time you tell to file a bug with Google, I'm at a loss, because I really have no idea how to explain this in technical terms to their engineers. "An app I'm using in Chrome starts to lag until I force garbage collection"? They will probably redirect me back to you.

  • Hi Ashley,

    If you recall, there have been several posts about the poor performance of C3 editor in Chrome and Edge. When working with fairly large projects, there are random lags and freezes lasting from a fraction of a second to 10-20 seconds.

    What's weird is that these issues are isolated not just to the browser app, but to a single browser tab. I can have two or three editors open in Chrome and only one of them will be freezing and the other two tabs will be working perfectly fine.

    Seems like we found the possible cause of the issue - garbage collection!

    Clicking the "Collect garbage" icon in DevTools immediately reduces or completely removes the lags. Please see the videos in previous comments. Here is also a report from relixes on Discord:

    Unfortunately, the effect is temporary. In my case the lagging returns after 5-15 minutes, so I have to keep the DevTools open and click that button many times a day.

    Can you please do something about this? Perhaps there is some "garbage collection aggressiveness" setting which should be increased, or maybe you could force it to run every 1 minute or so.

  • SnipG I don't use timelines. And I tried closing all tabs in the project, restarting the editor and only working in one or two event sheets - it still starts lagging randomly. So it doesn't look like the number of open UI windows/tabs is what's causing these freezes.

    The good news is that garbage collection definitely helps! Here it reduces 2-3 seconds lag to zero:

    Subscribe to Construct videos now
  • In C3 events are executed from top to bottom. Their order on the event sheet and the way they are nested is pretty important! It determines the order in which the actions are run, and the scope of picked instances.

    See this screenshot with my comments in it. The red numbers show the order in which the actions will run.

dop2000's avatar

dop2000

Member since 26 May, 2016

Twitter
dop2000 has 262 followers

Connect with dop2000

Trophy Case

  • 8-Year Club
  • Entrepreneur Sold something in the asset store
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Forum Wizard Made 5,000 posts in the forums
  • Forum Unicorn Made 10,000 posts in the forums
  • x5
    Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • Unrelenting Visitor Visited Construct.net 180 days in a row
  • Continuous Visitor Visited Construct.net 365 days in a row
  • RTFM Read the fabulous manual
  • x3
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x13
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

28/44
How to earn trophies