Jittering physics sprites when using per-object time scale on Xcode build but not remote preview

Not favoritedFavorited Favorited 0 favourites
  • 6 posts
From the Asset Store
Hand-painted tiles, objects, animated objects, and background to build a colorful Mayan civilization environment.
  • Hi,

    In my physics-based hybrid pinball/basketball game, I implemented “myTimeScale” – a global that I used to define the game speed by setting the project’s time scale to it. I then multiplied various timers in the game by it to compensate. To pause, I set the project’s time scale to zero, then explicitly set the time scale of various objects that I needed to be active during pause (such as UI buttons) to 1.0.

    I then decided to simplify things by switching things around. I realised that out of many objects in the game, I only needed to change the timescale of the ball and flippers, so created a family for these and set its time to “myTimeScale”. I then scrapped compensating the timers and setting various objects’ time scales to 1.0 on pause.

    This works perfectly except that when I build for iOS using Xcode, there’s noticeable jitter of the ball when it causes the screen to scroll upwards (I have an invisible sprite attached several pixels below the ball with the follow behaviour).

    When I run the game using remote preview, the jittering doesn’t occur. This is happening on a gen 10 iPad.

    Can anyone think of a reason why this might be happening?

    If not, it looks like I’ll have to revert to the original method.

    Thanks!

  • Can you show your code so that we can take a look?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I've spent some time troubleshooting this and figured it's nothing to do with the time scale.

    So I started going back over old versions - building them for Xcode and installing.

    Every build showed the jittering.

    So I downloaded my last released version from the App Store - no jittering.

    Then I exported that version's .c3p to Xcode and see the jittering again.

    So I think there's something changed in either Xcode or in Construct's build pipeline.

    But it doesn't happen on my iPhone!!!

    I don't want to share my entire project, but could try making a minimal one.

  • Does your project use scripting? It seems like there are some issues at the moment, so keep an eye on it.

    You could also try to export using older versions of Construct to see if the issue persist.

    If you find something let me know :)

  • I don't usually keep my exported Xcode projects, but I do use Google Drive to transfer them from my laptop to my Mac to build.

    I found an exported zipped Xcode project from January in the trash and restored it. Unzipped it, built in in Xcode and installed it - no jittering.

    So I opened the same project in Construct, exported it again as an Xcode project, built it and now the jittering returned.

    In summary, a project exported and built in January doesn't jitter but the same project exported and built today does.

    So it seems like some change in Construct's exporter has done this.

    I'll some more troubleshooting later - like run a diff on the Xcode projects' folders and also try to create a minimal project.

    (Note this only happens on an iPad running an exported Xcode project. The same project runs fine on an iPhone and fine on both if using remote preview).

  • Found the issue - I have a drawing canvas I clear then draw to every tick. When I remove that, all is good. I'll file an issue.

    EDIT - done: github.com/Scirra/Construct-bugs/issues/8519

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)