Why does it work? by DonGato
5 posters
Page 1 of 1
Why does it work? by DonGato
Hey guys,
I'm going to be explaining how different tricks and glitches work in this thread (not all at once, but I will keep adding to it). This is not about how to do the tricks, but rather an explanation as to why they work. I have been formulating theories as to how it all works for a long time now, and I now have the resources to verify my theories.
First, I need to introduce a couple of basic principles, which many tricks rely on
The Piecewise Movement Principle
In Exit Path players move in a series of small positional jumps, rather than smoothly transitioning from one position to another. Collision is calculated only at the destination of each jump.
The Frame Dependent Movement Principle
Movement is calculated frame by frame, with no relation to actual time. One jump happens per frame
Constants
Player Hitbox Size(pixels): 13.8 wide by 15 tall
Player Max Horizontal Speed: 20 pixels/jump
Player Max Vertical Speed: 20 pixels/jump
I will start with Ghosting, which comes in two flavors
Vertical Ghosting
The most common sort, when you go through a horizontal spike while moving either upwards or downwards.
Explanation:
This one is quite simple. First off, when pressing duck, the height of a players hitbox is scaled to 0.5, so he effectively becomes only 7.5 pixels tall. The hitbox for a spike is also 7.5 pixels tall. Adding the two together, we find that there is a vertical distance of 15 pixels in which the two hitboxes overlap. If the hitboxes overlap, you die. Fortunately the max vertical speed is 20 pixels per jump, so if you are moving downwards(or upwards) at max speed, and your position is calculated to be within 5 pixels of the spike's hitbox, on the following jump you will be on the other side of the spike.
In the case of two opposing spikes, such as this:
[You must be registered and logged in to see this image.]
My position is actually calculated between the two spikes (There are 10 pixels between their hitboxes).
Horizontal Ghosting
When you are moving horizontally through vertically oriented spikes.
[You must be registered and logged in to see this image.]
I used to think that this worked in the same way as vertical ghosting. As such I was sure that it must be possible to ghost horizontally through spikes without pressing down, as pressing down has no effect on hitbox width.
I was wrong.
Explanation:
As I mentioned above, the height of a spike's hitbox is 7.5 pixels, and here the spikes are rotated ±90 degrees. The width of the players hitbox is 13.8 pixels. 13.8 + 7.5 = 21.3, which is greater than the 20 pixel/jump horizontal speed limit, so the regular mechanism of ghosting doesn't work horizontally.
What i didn't mention above is that a spike's hitbox is only 16.45 pixels wide, as opposed to the 25 pixel wide graphical appearance. This means that two side by side spikes have a space of 25 - 16.45 = 8.55 pixels between them, which is small enough for our players' 7.5 pixel height when holding down.
This means that speed does not in fact matter in horizontal ghosting, only height relative to the spikes is important. That said, you have to move quickly enough for your vertical position to stay within a 8.55 - 7.5 = 1.05 pixel range while performing the trick.
More to come. I will also consider requests.
I'm going to be explaining how different tricks and glitches work in this thread (not all at once, but I will keep adding to it). This is not about how to do the tricks, but rather an explanation as to why they work. I have been formulating theories as to how it all works for a long time now, and I now have the resources to verify my theories.
First, I need to introduce a couple of basic principles, which many tricks rely on
The Piecewise Movement Principle
In Exit Path players move in a series of small positional jumps, rather than smoothly transitioning from one position to another. Collision is calculated only at the destination of each jump.
The Frame Dependent Movement Principle
Movement is calculated frame by frame, with no relation to actual time. One jump happens per frame
Constants
Player Hitbox Size(pixels): 13.8 wide by 15 tall
Player Max Horizontal Speed: 20 pixels/jump
Player Max Vertical Speed: 20 pixels/jump
I will start with Ghosting, which comes in two flavors
Vertical Ghosting
The most common sort, when you go through a horizontal spike while moving either upwards or downwards.
Explanation:
This one is quite simple. First off, when pressing duck, the height of a players hitbox is scaled to 0.5, so he effectively becomes only 7.5 pixels tall. The hitbox for a spike is also 7.5 pixels tall. Adding the two together, we find that there is a vertical distance of 15 pixels in which the two hitboxes overlap. If the hitboxes overlap, you die. Fortunately the max vertical speed is 20 pixels per jump, so if you are moving downwards(or upwards) at max speed, and your position is calculated to be within 5 pixels of the spike's hitbox, on the following jump you will be on the other side of the spike.
In the case of two opposing spikes, such as this:
[You must be registered and logged in to see this image.]
My position is actually calculated between the two spikes (There are 10 pixels between their hitboxes).
Horizontal Ghosting
When you are moving horizontally through vertically oriented spikes.
[You must be registered and logged in to see this image.]
I used to think that this worked in the same way as vertical ghosting. As such I was sure that it must be possible to ghost horizontally through spikes without pressing down, as pressing down has no effect on hitbox width.
I was wrong.
Explanation:
As I mentioned above, the height of a spike's hitbox is 7.5 pixels, and here the spikes are rotated ±90 degrees. The width of the players hitbox is 13.8 pixels. 13.8 + 7.5 = 21.3, which is greater than the 20 pixel/jump horizontal speed limit, so the regular mechanism of ghosting doesn't work horizontally.
What i didn't mention above is that a spike's hitbox is only 16.45 pixels wide, as opposed to the 25 pixel wide graphical appearance. This means that two side by side spikes have a space of 25 - 16.45 = 8.55 pixels between them, which is small enough for our players' 7.5 pixel height when holding down.
This means that speed does not in fact matter in horizontal ghosting, only height relative to the spikes is important. That said, you have to move quickly enough for your vertical position to stay within a 8.55 - 7.5 = 1.05 pixel range while performing the trick.
More to come. I will also consider requests.
Last edited by Don.Gato on Sat Jan 17, 2015 6:13 pm; edited 1 time in total
Don.Gato- Posts : 163
Join date : 2013-07-29
Age : 29
Re: Why does it work? by DonGato
Just using your above explanations, I can imagine why sticking into the bottom of blocks works now... You could write that up if you'd like.
Another thing I'm curious about is why you can get a wall jump at only certain distances, while others do not work, even with full speed. (Such as 3, 5, 9, etc) or... why some work only in one direction.
Thanks for this interesting article!
Another thing I'm curious about is why you can get a wall jump at only certain distances, while others do not work, even with full speed. (Such as 3, 5, 9, etc) or... why some work only in one direction.
Thanks for this interesting article!
AngelOfOreos- Cookie
- Posts : 709
Join date : 2013-09-23
Age : 24
Location : the mountains
Re: Why does it work? by DonGato
You must be a genius, there was so much math in this, and I couldn't understand any of it
ExitPathGirl16- Posts : 1063
Join date : 2013-08-29
Age : 24
Re: Why does it work? by DonGato
Please explain why moderators cannot have god modes like minecraft (I dont play minecraft myself though)
dragon144- Administrator
- Posts : 390
Join date : 2013-07-28
Re: Why does it work? by DonGato
dragon144 wrote:Please explain why moderators cannot have god modes like minecraft (I dont play minecraft myself though)
yck pls
AngelOfOreos- Cookie
- Posts : 709
Join date : 2013-09-23
Age : 24
Location : the mountains
Re: Why does it work? by DonGato
AngelOfOreos wrote:dragon144 wrote:Please explain why moderators cannot have god modes like minecraft (I dont play minecraft myself though)
yck pls
Im just kidding....
dragon144- Administrator
- Posts : 390
Join date : 2013-07-28
Re: Why does it work? by DonGato
Don, you are amazing. I think very highly of you, and I hope you know that...
Guest_Phoenix94305- Posts : 237
Join date : 2013-07-28
Re: Why does it work? by DonGato
Same hereGuest_Phoenix94305 wrote:Don, you are amazing. I think very highly of you, and I hope you know that...
Thanks Don
ExitPathGirl16- Posts : 1063
Join date : 2013-08-29
Age : 24
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
|
|