Practice mod (w/ slowdown fix as well)
6 years ago
Pohjois-Karjala, Finland

The preferred home of the program is now DefyGravityPracticeMod GitHub Repository, so post any issues or feature modification (game bugfixes, new features to practice mod, etc.) there. Download the latest release

This post won't be updated further.

[Section=About] The Practice Mod modifies the game in such a way that practicing speedrunning strats in different levels is easier. Features include single-level practice mode, with or without checkpoints active, as well as a level changer.

Also included is a timing fix for computers affected with the slowdown, and in-fact the timing fix is the recommended way to play for anyone. VSync needs to be on for this fix to work.

In case the smooth timing fix doesn't work for everyone (it should work, but of course things can happen and PC configurations vary), you will see a small red dot in the left corner. It is designed to be very, very unobtrusive, as to not affect gameplay or distract in any way. This dot means you should use the experimental timing fix, which synchronizes frames so that there is always internal 60Hz updates.

The smooth fix is the recommended one (toggled with F1 while on practice mode, and remembered outside of practice mode and saved in config) for a reason: the 60Hz synchronized internal updates introduces a small stutter, that's sometimes luckily unnnoticeable, but sometimes very pronounced.

Synchronize mode (experimental fix) can be enabled with F2 while on practice mode.

You can of course play with the red dot on, but that means the runs aren't eligible for speedrun.com verifications, as there is potential for abuse with it.

The official home of the Defy Gravity Practice Mod is https://github.com/jkarkkainen/DefyGravityPracticeMod

[Section=Updates] [big]Version 8.3[/big] Added texturepack support and autoupdater.

[big]Version 6[/big] Combined timing fix with isFixedTimeStep -fix without needing the synchronizing fix. This results in the best possible timing fix for Defy Gravity - VSync keeps the logic updates to 60Hz with dropping updates or catching up, resulting in the smoothest possible, yet correct experience.

In case it happens that the framerate doesn't stabilize in-game to 60 fps, the mod draws a small, nearly unnoticeable (to be as unobtrusive as possible) red dot in the left corner when not in Practice Mode. In case you keep seeing this red dot, your computer still can't do consistent 60 fps, and you have to forego the smoothness with the syncronized version.

F1 to enable the smooth timing fix F2 to enable syncronized timing fix (in case the fps still doesn't keep up)

[big]Version 5[/big]

  • Implemented experimental timing fix. Press F2 to toggle it. Added to saved config.
  • Added VSync toggle to F3. Added to saved config.

For best results with the experimental timing fix, activate both the old slowdown fix and the experimental one. Without both of them, you WILL get correct updates, but it will be a bit jerky, as the experimental fix has to play catch-up every now and then.

Vsync toggle is kind of a novelty: sure, you could run the game with 1200 fps, but as the internal logic is updated only 60 fps, and there is no graphics element interpolation between frames, you won't get anything out of it.

[big]Version 4[/big] Added proper identifier by changing the assembly name of the executable. Eases identifying in the autosplitter.

[big]Version 3[/big]

  • Changed the hotkey for enabling practice mode back to F10 - I forgot F12 was the default screenshot key in Steam (which is why I've been using F10 for my default hotkey, but completely forgot)
  • Included the slowdown fix as a toggleable option so I can just keep modifying one version of the mod. When in practice mode, toggle the slowdown fix with F1. The practice mode doesn't need to be on for it to be active. The setting is also saved and loaded when the game is started.
  • Fixed the game bug where the showLevelTime -setting isn't respected or saved at all.

[big]Version 2[/big]

  • The IGT level timer is now reset whenever you start the level from beginning when in practice. This means when you die with checkpoints active but haven't activated any yet, or when your checkpoints are disabled and you die.
  • Added Tab -button to toggle HARD mode. Eases the navigation of levels a bit.

[Section=Hey There!] I modified the game exe and implemented an individual level practicing functionality.

By pressing F10, you activate Practice Mode. Practice mode means that when you reach the exit, instead of loading the next level, the current level is restarted. You can toggle two practice modes (or practice off) with F10:

  • Level Practice with checkpoints When exiting, current level is reloaded. When dying, player is respawned to last checkpoint, as usual.
  • Level Practice without checkpoints When exiting OR dying, the current level is reloaded. Checkpoints are skipped.

Pressing PageUp and PageDown loads the previous or next level, respectively. The loaded levels are cycled from Normal 1 to 24 to Hard 1 to 24, both directions.

To prevent subterfuge, when the practice controls are active, the text "Level Practice" and level index and difficulty if hard is shown on the top-left corner.

When inside the practice mode, the following keys are also active: F1 - Disable Fixed Timestep (Old slowdownfix) F2 - Enable Experimental Timing Fix F3 - VSync off

Best results for fixing timing and framerate is to enable both F1 and F2. All the settings are remembered, so to resume normal play with the settings on, just cycle out of practice mode with F10. The settings are also saved and loaded on game start.

Main link

Alternate link

Happy practicing, and do tell me if something isn't working right! I'll be happy to fix if any problems arise!

PS. ALL the exes across ALL systems should be now compatible with the autosplitter! Do note that using the autosplitter with practice mode and especially changing levels manually WILL mess up your splits.The reason it's supported is that you can use LiveSplit for timing, undo the splits and then do a proper run with practice mode off, all without closing or restarting any progams.

EDIT: One bug I found out was that if you spam the PageDown (or previous level key) the game will crash. So, easy does, after the level fade-in has started, it's safe to press again.

Also, any suggestions for the mod? I was thinking about resetting the timer on death if practice mode is on and checkpoints are disabled. Anything else? How would you like to see the practice mod work with the autosplitter? For instance, everytime the timer is reset, I could set the autosplitter to duplicate current split and split - that wouid keep a record of the practice run, but it would DEFINITELY mess up your splits.

Throw anything you think about to me, and I'll see if it's feasible and I have the time to do it!

[section=Ideas] Fix level timer not resetting when entering main menu[big][big]DONE[/big][/big] Not a big deal, but it annoys the heck out of me.

Find out how to make the game frame-rate independent[big][big]DONE[/big][/big] Most probably this will be so big an ordeal that I'm not even gonna attempt it. However, I have a few ideas that, if any of them pan out, would actually make the fix quite simple. We'll see.

Fix animations when in slowdownfix -mode[big][big]FIXED IN EXPERIMENTAL[/big][/big] The running animation can be so hectic that it's actually distracting.

Autosplitter coupling[big][big]DONE[/big][/big] Hmm. How about if the autosplitter checks whether we are in practice mode or not, and if we are, restart the timer on dying (if we are in no checkpoint mode) and level exit, but on level exit save the time to a UI control where you show the last level exit time? This wouldn't mess up the splits at all, and you'd get some feedback on how well you did.

Hard mode toggle [big][big]DONE[/big][/big] In addition to cycling the levels through hard mode, add a Key to toggle Hard mode. What would be a good key for it? Tab?

Fix in-game timer [big][big]DONE[/big][/big] Currently the in-game level timer keeps on going when dying. If you are practicing with checkpoints, you might actually want this behaviour, but when you are practicing without checkpoints, you'd most probably want to reset the timer everytime you die.

[Section=Bug Reports] If you have any issues with the mod, you can either comment on this post, or visit the mod's GitHub Issues page

and create a new issue. Feature requests are also welcome.

Edited by the author 6 years ago
Thermospore, Timopy, and Garita like this
Pohjois-Karjala, Finland

Updated to version 5 and improved the welcome text a bit.

Timopy likes this
Finland

You're the hero we need but don't deserve. The new version completely fixes the game for me, crazy!

Pohjois-Karjala, Finland

Updated to Version 6, included the link to the github project page, and wrote a wall-of-text about.

Game stats
Followers
18
Runs
92
Players
14
Latest threads
Posted 4 years ago
3 replies
Posted 6 years ago
1 reply
Posted 6 years ago
2 replies
Posted 6 years ago
1 reply