Jan 31, 2011 at 7:43 PM
Join Date: May 22, 2008
Location:
Posts: 35
The Physics of Cave Story - V.6 Released
[Updates] Using the knowledge gathered by the helpful members of the forum, a java program was created to show how far the understandings of technological aspects of Cave Story's physics have come, the bottom of this post contains the latest instructions and file.
[op]
While considering Cave Story, as many of us once have, I stumbled upon a thought; never again will I play another platformer and love it as much as I do Cave Story because it will never feel the same. This led to the question of "What is the feel of Cave Story?". The answer appears to be non-trivial, Pixel obviously spent his time fine tuning the game to a high degree of precision. I plan to spend some spare time in the coming months discovering the exact pseudo-code style way Cave Story handles the physics of player simulation and camera-movement. I'm placing a list out in this post so that if anyone wants to help me, they can! Please feel free to help expand the list or suggest values.
[EDIT] The forums are a terrible place to store information and collaborate on it. To that end, the list has been transformed into a design document. This document comes in two variations:
Publicly Editable and Viewable *Updated Infrequently*: https://docs.google.com/document/d/1jmHGorrZlM8-X4QkDetLOXskcAmhMa6lwNLt22SIvho/edit?hl=en
Protected Static and Viewable *Updated First Always*: https://docs.google.com/document/d/1wr7RKzmb0UC2abh_2HfyIMN8N-JDGwBFaNHUJmpKxRs/edit?hl=en
If people use the public document responsibly, I will transfer their information to the protected document, leave your name if you wish for credit!
This setup will prevent vandalism... I hope
Just to be absolutely clear on this, what I really want is numeric values and formulas that define how quote interacts with collision and input. So, is a jump modeled as an impulse? a change in velocity in the y? Is gravity kinematically calculated by an artificial acceleration? pseudo-acceleration by a frame by frame decrease of velocity? When quote bumps his head is this an elastic/inelastic collision, does gravity effect him differently in this case? What is terminal velocity? For the camera, is the center of the camera attracted to the center of quote? if so by what amount of force/acceleration/constant velocity?
My best bet is to dissect the source code from the NXEngine code: http://nxengine.sourceforge.net/
It uses some advanced coding practices so I am trying to rip out the pure physics into an easy to understand beginner level.
More Sources:
http://www.cavestory.org/forums/threads/792/
And thanks to Noxid for some code
[/op]
_________________________________________
Release 6: Refactory!
Releases For Testing: dist* = application only, arkiv* = application and src files
Feb. 18/11dist
Feb. 19/11dist2
Feb. 21/11dist3
\____>dist4
The above versions work for mac computers only, the below should be multiplatform
Feb. 25/11Arkiv
Mar. 29/11Arkiv1
Instructions:
1. Unpack the distribution
2. Open terminal and type:
java -Djava.library.path="*" -jar "**"
where * is the path to the /lib directory inside /dist
and ** is the path to the cavestoryphysics.jar
3. Laugh at my terrible programming skills
[Updates] Using the knowledge gathered by the helpful members of the forum, a java program was created to show how far the understandings of technological aspects of Cave Story's physics have come, the bottom of this post contains the latest instructions and file.
[op]
While considering Cave Story, as many of us once have, I stumbled upon a thought; never again will I play another platformer and love it as much as I do Cave Story because it will never feel the same. This led to the question of "What is the feel of Cave Story?". The answer appears to be non-trivial, Pixel obviously spent his time fine tuning the game to a high degree of precision. I plan to spend some spare time in the coming months discovering the exact pseudo-code style way Cave Story handles the physics of player simulation and camera-movement. I'm placing a list out in this post so that if anyone wants to help me, they can! Please feel free to help expand the list or suggest values.
[EDIT] The forums are a terrible place to store information and collaborate on it. To that end, the list has been transformed into a design document. This document comes in two variations:
Publicly Editable and Viewable *Updated Infrequently*: https://docs.google.com/document/d/1jmHGorrZlM8-X4QkDetLOXskcAmhMa6lwNLt22SIvho/edit?hl=en
Protected Static and Viewable *Updated First Always*: https://docs.google.com/document/d/1wr7RKzmb0UC2abh_2HfyIMN8N-JDGwBFaNHUJmpKxRs/edit?hl=en
If people use the public document responsibly, I will transfer their information to the protected document, leave your name if you wish for credit!
This setup will prevent vandalism... I hope
Just to be absolutely clear on this, what I really want is numeric values and formulas that define how quote interacts with collision and input. So, is a jump modeled as an impulse? a change in velocity in the y? Is gravity kinematically calculated by an artificial acceleration? pseudo-acceleration by a frame by frame decrease of velocity? When quote bumps his head is this an elastic/inelastic collision, does gravity effect him differently in this case? What is terminal velocity? For the camera, is the center of the camera attracted to the center of quote? if so by what amount of force/acceleration/constant velocity?
My best bet is to dissect the source code from the NXEngine code: http://nxengine.sourceforge.net/
It uses some advanced coding practices so I am trying to rip out the pure physics into an easy to understand beginner level.
More Sources:
http://www.cavestory.org/forums/threads/792/
And thanks to Noxid for some code
[/op]
_________________________________________
Release 6: Refactory!
Releases For Testing: dist* = application only, arkiv* = application and src files
Feb. 18/11dist
Feb. 19/11dist2
Feb. 21/11dist3
\____>dist4
The above versions work for mac computers only, the below should be multiplatform
Feb. 25/11Arkiv
Mar. 29/11Arkiv1
Instructions:
1. Unpack the distribution
2. Open terminal and type:
java -Djava.library.path="*" -jar "**"
where * is the path to the /lib directory inside /dist
and ** is the path to the cavestoryphysics.jar
3. Laugh at my terrible programming skills