On Wall Clips, the Physics Engine, Frame Rate, and the Portal Mappack
9 months ago
Pennsylvania, USA

Hi. I'm Lexi. I speedrun, TAS, and mod this game. You might have noticed the recent RTA world records in the Portal category feature some brand new tech never seen before outside of I and @Masterjun's tool assisted speedruns. I'd like to talk about how they work and how to perform them yourself, and introduce for discussion a speedrunning mod I've made for the game.

To start, the physics. If you've ever watched a pannenkoek video, you probably know that games perform physics updates in steps. The more steps done each second, the more incremental the changes in each step, and the less likely it is for these incremental changes to somehow clip the player through a wall. Well, Mari0 has no such incremental step system. Or rather, the physics is stepped only once every frame. This means that, the lower the FPS the game runs at, the easier it is to clip through walls and floors, because there will be less physics updates each second, and thus Mario will move a larger amount on each update to compensate. (Don't worry, this is about as deep into the technical details that this post will go.)

Now, Maurice knew about this while he was creating the game, and thus he enforces a minimum frame rate of 1/0.01666667, which is roughly (microscopically under) 60FPS. If your computer can't keep up with this minimum then the game will just run slow so that Mario doesn't clip through the floor and die just from jumping too high. While he coded in this minimum frame rate, he unfortunately did not code in an option to set a maximum frame rate which is necessary to perform these new clips. Though, I'm getting a bit ahead of myself- first I should talk about what these new clips are and how to perform them.

The clip in 1-1 is pretty much as simple as it looks, though it's highly dependent on frame rate. In fact, if you play on the lowest possible frame rate, then the only way to quickly get the clip is to fire the wall portal and hold Run+Left after performing six loops (so, entering the portal on the floor six times). Different frame rates will allow you to clip at different times and in different ways (i.e. in my PB, my game was apparently not running at a perfect minimum, so I was able to clip without holding anything (or maybe I was holding Right, I don't remember)).

The first clip in 1-4 was pioneered by @WilliamFrog and has different setups depending on your frame rate. William's setup of performing a full height jump into the wall then hanging back (only after trying to clip just by falling from the upper platform) works best for him on his ~60 FPS limit, though for my roughly minimum FPS limit I use a different setup he created which involves doing a full jump off the cube and then hanging left. Either way, you want the majority (but not all) of Mario's body to be over the tile to the right of the floor portal as you clip, and you want to be holding left.

The emancipation grill clip in 1-4 is a bit older and simpler in that it's not so framerate dependent, but harder in that it's a frame perfect trick. My simple setup for it is to drop the cube a little before the kill point and then lightly mash the Right key, with the goal being that I press it for just a single frame each time until the cube is past the kill point. William's setup is no setup, he's just a god gamer who can nail the frame perfect drop past the kill point consistently.

In 2-3, William goes for a strat which I think is relatively straightforward to understand just from watching it, though it's quite difficult to actually pull off. I haven't learned it yet because it's hard and it's not necessary for WR yet so I don't remember the exact timing to pull it off, I'll edit in here later.

(apparently SRC has a character limit now, see reply for the rest of this post.)

편집한 사람 작성자 9 months ago
Pennsylvania, USA

(...continued)

And for now that's just about it for clip strats. There's a couple other known clips but they're not any faster (yet, I guess). So, since Mari0 doesn't have a max FPS option, how do you pull these off? The easiest option is to enable VSync in the game's settings and then set your monitor's refresh rate to 60Hz. However, if you mod the game to print out the FPS each frame, you'll notice that it fluctuates by a tiny fraction each frame which can affect the consistency of these clips. Another option is to set a ~59 FPS limit through an external program like the NVIDIA Control Panel, which would effectively make the game run ever so slightly slower but more consistent. This is what I've used for all my runs, and while I think tools like this are pretty accessible, I understand some might frown upon this option, which is why...

I've created a speedrunning mod for the game! It features a built-in FPS limiter you can use to consistently run the game at the lowest possible frame rate with absolutely zero fractional deviation. The mod is very non-invasive-- it doesn't touch the minimum FPS code whatsoever so there's no way to make clips even easier than they are in the vanilla game. All it does is it modifies the main thread loop to wait until 1/60 of a second has elapsed before calling the physics and graphics update functions, and tells a little white lie to the physics function about how much time has passed (it always reports that exactly 1/60 of a second has passed instead of the actual true time it took). This allows the game to run at full speed and run at the lowest possible FPS constantly, something which is not possible through either other FPS limiting method. Oh, and it adds a LiveSplit.Server autosplitter and load time remover. The code is all open source so you can confirm for yourself how little game code it changes.

So, I would like to formally request an addition to the rules to allow (and perhaps even encourage, for the load time removal) the usage of this mod. My credentials for making this request are that I am a longtime contributor of fixes for this game and its most popular mod. I have tested the mod extensively to ensure the frame rate limiter is accurate and provides no gameplay advantages over the vanilla game. (I have even submitted the mod for inclusion in the vanilla game, though Maurice has not yet provided much comment on it. Most mods he has pulled in have been bug fixes so it's not all too surprising he would be reluctant to pull in a new feature.) Thank you to whoever reads this and comments on my proposal :)

게임 통계
팔로워
72
런들
114
플레이어
34
최근 쓰레드
게시 일자 9 months ago
1 개의 답글
게시 일자 5 years ago
4 개의 답글
게시 일자 1 month ago
0 개의 답글
게시 일자 5 years ago
2 개의 답글
게시 일자 5 years ago
0 개의 답글