Ashley's Recent Forum Activity

  • The edit-time restrictions are very general purpose, e.g. preventing two triggers in one event. It's true the C2 event system has no model for exceptions - typically things resort to empty values or no-ops, which I think is reasonable given the goal of making the event system easy to use: instead of trying to figure out why exceptions are breaking everything, events tend to continue to work anyway. Some plugins use an "On error" trigger so the user can find out if something went wrong, I'd suggest using that model as well.

  • The files in the original report are definitely MP3 files, which is almost certainly the cause of the reported issue. If you think there are any other issues here, please file separate reports for them.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I've not been able to reliably reproduce this on an iPad Air 2 running iOS 9.2 - occasionally when bringing back Safari the audio would seem to cut out, but I never heard it playing distorted, and after a while it just worked every time. I'm not sure there's much we can do anyway - it sounds like a bug in iOS and the workarounds I've seen basically involve destroying the audio context and recreating it, but that is very difficult given C2's audio engine as pre-allocated audio buffers and effect chains which would all also need to be torn down and recreated, and then trying to support resuming audio (like the way music resumes when you bring back the app) would be incredibly difficult. I think we will just have to wait it out and hope the next iOS update fixes it.

  • Perhaps it's the same problem as this?: https://www.scirra.com/forum/sound-stop-playing-after-a-short-break-of-inactivity_t166126

    In that report, if Chrome for Android sits idle for 30-60 seconds not playing any audio at all, there's a bug that stops any more audio playing. It's a bug in Chrome (linked to in that thread) and there should be a workaround in the next build. Maybe that will fix it.

  • I found the problem in the end: those aren't Ogg files, they're MP3 files which were just renamed to .ogg. NW.js can't play MP3 files but Chrome can. So in fact you must have incorrectly imported the files somehow, or did you think renaming the file would convert it? (It doesn't!)

    This also explains why Asmodean's workaround works: you convert the MP3 to WAV, then re-import it, then C2 encodes a correct Ogg Vorbis file.

    NW.js should always report useOgg = true in the console. I just double-checked this and it does. The dopplerFactor message is irrelevant.

  • I can't reproduce this on a Nexus 9 (Android). Are you sure the iPhone 6S hardware supports multiple force touches? I've not seen any references indicating multitouch works with force touch simultaneously, especially since it's awkward to force-touch with one finger and then use another finger to do a separate touch somewhere else. So it might just be that this is not a feature of the device!

  • Should be fixed in the next build.

  • This is tricky to work around - if you type on the comment box on this page, you can still select its text sometimes by dragging from outside the textbox. It even seems to focus the control sometimes, even though the click started outside the control. This kind of browser-default behavior is tricky to correctly disable: if you just say "disable mouse moves", then you can't select text at all inside the control, but trying to define how to say "disable when the click did not originate from this control" requires app-wide pointer tracking with support for mouse, touch and pointer events for cross-browser support, and co-operation between different plugins that need this kind of feature. So it's actually pretty complicated.

    I think it's a fairly minor issue that is easy to workaround with that event, but I'll leave the report open in case future refactoring of the runtime can resolve this.

  • This appears to be a bug in Chrome. Star this report to follow updates: https://code.google.com/p/chromium/issues/detail?id=518863

    I think I found a workaround which I've integrated in to the next build: it will play a silent sound every 25 seconds, to avoid the 30 seconds of silence detection which seems to shut down Web Audio. It seems to work here, but I'm not sure if it covers every possible case. Anyway, star the issue and hopefully Google will fix the real problem soon.

  • Thanks, should be fixed in the next build.

  • This is a variant of "Expecting math calculations to be exact" in common mis-used events and gotchas. R0J0hound is right that you are running in to the precision limits of floating point numbers on computers, so closing as won't fix.

    You only need to hold down W for a short while to get 100,000,000 pixels away. Internally the engine stores positions as double-precision floats, which have integer precision up to 2^53 (= 9007199254740992). However for performance reasons the renderer uses single-precision floats, since this uses half the memory bandwidth, is faster to process, and is still perfectly suitable for virtually all realistic uses. This means when it comes to draw the object it only has integer precision up to 2^23, which is 8,388,608. Basically beyond that point there will be rounding due to the limited precision, and the further you go the more severe the rounding is, which appears as the object shaking as it goes further.

    Making the renderer use full double-precision floats would cause all games to take a performance hit. This is a really extreme example which it should be easy to work around: you don't really need to move the object that far, you can do a lot with just faking it (e.g. not actually scrolling but showing stars in the background shooting past really fast, or something similar). As far as I can tell from a quick glance at the source, CC also used single-precision floats in its renderer, so ought to be subject to the same problem, but maybe I forgot some aspect of the renderer that uses better precision. CC is officially retired and hasn't been updated for years though, so I would say don't even consider it!

  • Closing, review the bug report guidelines on how to provide a useful .capx that you can share.

Ashley's avatar

Ashley

Online Now
Early Adopter

Member since 21 May, 2007
Last online 27 Oct, 2026

Twitter
Ashley has 1,833,088 followers

Connect with Ashley

Trophy Case

  • 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
  • Forum Mega Brain Made 20,000 posts in the forums
  • x126
    Coach One of your tutorials has over 1,000 readers
  • x74
    Educator One of your tutorials has over 10,000 readers
  • x6
    Teacher One of your tutorials has over 100,000 readers
  • Sensei One of your tutorials has over 1,000,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • x44
    Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

32/44
How to earn trophies

Blogs