Problems with time scale

0 favourites
  • 3 posts
From the Asset Store
An educational game for Times Table. An easy to use template for developers to build larger games
  • Hello

    I'm having issues with time scaling. I recently put Mega Man-like scrolling into my project, where when the screen pans the player and enemies freeze. I did this by setting the time scale to 0. Then, when my moving camera has arrived to its destination, I have it set to put time scale back to normal.

    My death animation also uses time scale. It sets the speed to 0.15 to make it look like it's going in slow motion. However, since I implemented the freezing when the screen is panning, the death animation doesn't slow down anymore.

    However, when I go into debug mode and initiate the death animation, it shows that the time scale is 0.15, but with the speed the player is going it seems like the time scale definitely isn't 0.15.

    I know it has to do with the events that control freezing entities when the screen is panning (events 15 and 16 under scrpt_general), because when I delete those the death animation works fine. I'm just not sure exactly what's going on with it.

    Here is a link to my project files: https://drive.google.com/file/d/11hAqqt-x09S-tHeHuD4i5gR_vilu2KL_/view?usp=sharing

    To see the problem, walk directly into the cave and get hit by the enemy. The player will fly quickly back which isn't supposed to happen. To see how the death animation is supposed to look, delete events 15 and 16 under scrpt_general.

    Thanks

  • I think what happens is you make player's time scale=1, and everything else 0.15, so your player is not slowed down.

    You need to use "System restore object time scale" action, instead of "Set time scale=1"

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Awesome! That worked. Thanks!

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