[Ohrrpgce] Setting fps via scripts

Ralph Versteegen teeemcee at gmail.com
Mon Apr 8 16:32:07 PDT 2019


There's two different ways in which you might want to change the fps: so
that speed of the game, as perceived by the player, stays the same, or so
that it changes.

-In the first case movement and animation speeds adjust their pixels or
frames per tick to stay at the same pixels or frames per second. Not sure
about script waits and camera/slice movement commands: that might be the
responsibility of the script author, or we might add a bitset which makes
'wait' count in multiples of 55ms rather than ticks, etc.

-In the second case nothing is adjusted, so everything appears to move
slower/faster. Even keyrepeat speeds up/slows down if you want to be strict
about it. It's possible to increase the fps past 60, even to 1000.

The second case is useful for fast forwarding, as you might want in game
that lets you watch a replay of a level you just played. Someone did
request that of me. The script command for this would take a multiplier,
not a frame rate.

Potentially we could add commands for either or both of the above. I think
that for your use case (Axe dartle?) it would make no difference?
But I don't want to end up with a script command that causes some mixture
of the above effects... unfortunately, adjusting the framerate already does
: (

On Tue, 9 Apr 2019 at 03:32, James Paige <Bob at hamsterrepublic.com> wrote:

> I think I was hesitant about this before, but now I do really want to add
> scripting commands that can change fps on the fly
>
> The obvious use case for me is when you want to script a mini-game that
> runs at a different fps than the main game, but I am sure other people will
> come up with interesting ways to use it, and that is good.
>
> I am wondering how it should work. If we had floats in plotscripting it
> would be obvious, but since I want it to work with ints I am a bit unsure
> which is the best interface
> _______________________________________________
> Ohrrpgce mailing list
> ohrrpgce at lists.motherhamster.org
> http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.motherhamster.org/pipermail/ohrrpgce-motherhamster.org/attachments/20190409/5b099c7a/attachment.html>


More information about the Ohrrpgce mailing list