I just realized that the recent stable version of OHR automatically adjusts walk animations to look right in higher frame rates. WOW! THANKS!
Is there something I should be aware of before I start tweaking my game to run in 60 FPS?
Gotchas That I Already Discovered:
Battles are not in 60 FPS (I don't use the battle engine, so I'm good.)
Need to slow down hero walking speed.
WAIT commands need to have their ticks increased.
Tile animations need to be slowed down.
60 FPS!
Moderators: marionline, SDHawk
- Willy Elektrix
- Liquid Metal Slime
- Posts: 910
- Joined: Sun Aug 15, 2010 11:30 pm
60 FPS!
Last edited by Willy Elektrix on Thu Mar 19, 2020 9:44 pm, edited 1 time in total.
- Bob the Hamster
- Lord of the Slimes
- Posts: 7660
- Joined: Tue Oct 16, 2007 2:34 pm
- Location: Hamster Republic (Ontario Enclave)
- Contact:
- Willy Elektrix
- Liquid Metal Slime
- Posts: 910
- Joined: Sun Aug 15, 2010 11:30 pm
Did you hear that a few months ago someone came by wanting to record a Let's Play of Alien Squatter, but complained that the game was running at a low framerate. They didn't want to do it before the game gets upgraded to 60fps.
The only other thing to consider are slice and camera movement/velocity commands, which measure time in ticks.
Beware that the map and tileset editors display tile animations at the wrong speed if the game's fps isn't set to 18fps.
I suggest you do a search-replace of "wait(" in your scripts with "wait18(":
(If the original wait amount was 1 tick, then it assumes you're waiting until the next tick instead of waiting for a certain length of time.)
I think we should have some a builtin script equivalent to that, or a setting which automatically stretches all the wait commands without you having to do anything. Plus also a "wait ms" command to count time in (milli)seconds.
I'm planning to implement fractional movement speeds and add a setting to adjust all the walk speeds, so that if someone changes the framerate, all the movement speeds (as measured in pixels per second) stay the same. If you do it manually, it's not going to be a problem. I was hoping to get it into the next version, but that's really soon, so unlikely to happen before then.
Of course Alien Squatter has no moving NPCs (that' I'm aware of), so that's easy.
The only other thing to consider are slice and camera movement/velocity commands, which measure time in ticks.
Beware that the map and tileset editors display tile animations at the wrong speed if the game's fps isn't set to 18fps.
I suggest you do a search-replace of "wait(" in your scripts with "wait18(":
Code: Select all
script, wait18, ticks = 1, begin
if (ticks == 1) then (wait(1))
else (wait(ticks * 600 / 183)) # convert ticks from 60fps to 18.3fps
end
I think we should have some a builtin script equivalent to that, or a setting which automatically stretches all the wait commands without you having to do anything. Plus also a "wait ms" command to count time in (milli)seconds.
I'm planning to implement fractional movement speeds and add a setting to adjust all the walk speeds, so that if someone changes the framerate, all the movement speeds (as measured in pixels per second) stay the same. If you do it manually, it's not going to be a problem. I was hoping to get it into the next version, but that's really soon, so unlikely to happen before then.
Of course Alien Squatter has no moving NPCs (that' I'm aware of), so that's easy.
Last edited by TMC on Fri Mar 20, 2020 7:11 am, edited 1 time in total.
- Willy Elektrix
- Liquid Metal Slime
- Posts: 910
- Joined: Sun Aug 15, 2010 11:30 pm
I didn't know that!TMC wrote:Did you hear that a few months ago someone came by wanting to record a Let's Play of Alien Squatter, but complained that the game was running at a low framerate. They didn't want to do it before the game gets upgraded to 60fps.
Thanks for that script, that will be much easier than going in manually to edit all those scripts. As usual, you've been a big help!