Author Topic: [FEAT] Re-inroducing Superlemming!  (Read 2240 times)

0 Members and 1 Guest are viewing this topic.

Offline WillLem

  • Moderator
  • Posts: 3515
  • Unity isn't sameness, it's togetherness
    • View Profile
[FEAT] Re-inroducing Superlemming!
« on: February 14, 2023, 09:44:59 PM »
Re-inroduce Superlemming mode
- The mode will be available as a checkbox option in the Editor: "Activate Superlemming mode"
- Player-side, when active the framerate cap will increase to {?}, and all physics will move at {?}FPS | OR | the fast-forward button will be activated (least favourable option due to varying speeds)

Where I'm up to with this:

:tal-gold: Superlemming mode successfully reinroduced!



Archived:

Thinking that it might be worth looking at how Superlemming mode worked in Lemmix, old formats NeoLemmix and SuperLemmini, and also have a look at how Lix handles the variable fast-forward speeds.

Here is a useful document about how the application handles when not processing code. This may come in useful when looking at implementing Superlemming mode.
« Last Edit: May 28, 2024, 10:34:18 AM by WillLem »

Offline Simon

  • Administrator
  • Posts: 3935
    • View Profile
    • Lix
Re: [SuperLemmix] Re-inroducing Superlemming!
« Reply #1 on: February 14, 2023, 10:43:02 PM »
how Lix handles the variable fast-forward speeds.

The gist is:

    while true {
        if normal speed {
            advance physics only if it's been >= 1/15 of a second since advancing
        }
        else if normal fast-forward {
            advance physics
        }
        else if turbo-fast-forward {
            advance physics 9 times in a row
        }
        draw to screen
        wait, to heed the desired framerate of 60 fps
    }


The code for this is spread across different areas: The loop is the outermost game loop that runs independently from those speed decisions that only make sense while playing a level. If you'd like, we can look at it together while voicechatting in Mumble.

-- Simon
« Last Edit: February 26, 2023, 05:17:50 PM by WillLem »

Offline WillLem

  • Moderator
  • Posts: 3515
  • Unity isn't sameness, it's togetherness
    • View Profile
Re: [SuperLemmix] Re-inroducing Superlemming!
« Reply #2 on: February 15, 2023, 12:59:58 AM »
Interesting reply, Simon. Thanks!

advance physics only if it's been >= 1/15 of a second since advancing

Since advancing what?

else if turbo-fast-forward {
            advance physics 9 times in a row

How does this translate to a particular speed, though? Something could be done 9 times in a row but very slowly.

If you'd like, we can look at it together while voicechatting in Mumble.

This would be amazing! We'll sort out a date & time to do this, I'm sure it would be incredibly useful for me and hopefully at least mildy interesting for you :lemcat:
« Last Edit: February 26, 2023, 05:18:04 PM by WillLem »

Offline Simon

  • Administrator
  • Posts: 3935
    • View Profile
    • Lix
Re: [SuperLemmix] Re-inroducing Superlemming!
« Reply #3 on: February 15, 2023, 11:55:26 PM »
advance physics only if it's been >= 1/15 of a second since advancing
Since advancing what?

Since the most recent physics update, regardless of what caused that previous update.

Quote
else if turbo-fast-forward {
            advance physics 9 times in a row
How does this translate to a particular speed, though? Something could be done 9 times in a row but very slowly.

It isn't guaranteed to translate to a fixed real-time speed. The unlikely extreme case would be when a single physics update takes longer than drawing everything to screen.

Most people will manage 60 fps even at turbo-fast-forward, and then it will translate to 9 * 60 = 540 physics updates per second. When you don't manage 60 fps, it's still faster than anything else, and I hope it's sitll fast enough then to not bore anyone.

Singleplayer Lix isn't a dexterity challenge, and the fast-forwards aren't designed to run at a fixed real-time speed. Their speed merely caps at 60 or 540 physics updates per second. If you need to maintain a minimum speed, you'll have to do something else, e.g., frameskipping, than Lix does.

Multiplayer Lix is only runs at normal speed, never at fast-forward. Normal speed in multiplayer features speedup/slowdown to keep the players largely synched with each other, but that's beyond what I explained in the gist.

date & time to do this, I'm sure it would be incredibly useful

This Sunday, February 19th, in the evening? I can manage any of 16:00 UTC, 17:00 UTC, 18:00 UTC, 19:00 UTC, 20:00 UTC.

-- Simon
« Last Edit: February 26, 2023, 05:18:16 PM by WillLem »

Offline WillLem

  • Moderator
  • Posts: 3515
  • Unity isn't sameness, it's togetherness
    • View Profile
Re: [SuperLemmix] Re-inroducing Superlemming!
« Reply #4 on: February 17, 2023, 01:19:54 PM »
This Sunday, February 19th, in the evening? I can manage any of 16:00 UTC, 17:00 UTC, 18:00 UTC, 19:00 UTC, 20:00 UTC.

That would be great, thanks! Let's start early, I've put 16:00 UTC into my calendar :lemcat:
« Last Edit: February 26, 2023, 05:18:24 PM by WillLem »

Offline Simon

  • Administrator
  • Posts: 3935
    • View Profile
    • Lix
Re: [SuperLemmix] Re-inroducing Superlemming!
« Reply #5 on: February 17, 2023, 10:07:06 PM »
All right, 16:00 UTC this Sunday!

-- Simon
« Last Edit: February 26, 2023, 05:18:34 PM by WillLem »