v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Editing User:Larix/Minecart Collisions

Jump to navigation Jump to search

Warning: You are not logged in.
Your IP address will be recorded in this page's edit history.


The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
 
I explored the physics of minecart collisions a bit. These are my findings:
 
I explored the physics of minecart collisions a bit. These are my findings:
  
1. if a cart attempts to move into a tile currently occupied by another cart, it transfers its entire movement pulse to that cart and comes to a stop.  
+
1. if a cart attempts to move into a tile currently occupied by another cart, it transfers its entire movement pulse to that cart and comes to a stop. If it was moving faster than derail speed, it will also let go of its cargo.
*If it was moving faster than derail speed, it will also let go of its cargo.
 
*The pushed cart, if it is accelerated to above-derail speed from a standstill, will also spill its cargo.
 
*A cart accelerated to ''less'' than derail speed will keep its load, even if it was hit by a derail-speed cart.
 
  
 
2. the speed at which the pushed cart will move is
 
2. the speed at which the pushed cart will move is
incoming speed * incoming cart's weight/pushed cart's weight.
+
incoming speed * incoming cart's weight/pushed cart's weight  
*Normally that speed is capped to be no higher than incoming speed. Apart from the cap, that's plain old conservation of momentum, i think.  
+
capped at incoming speed. Apart from the cap, that's plain old conservation of momentum, i think.  
  
2a) any potential speed of the pushed cart in the same direction is ''lost without a trace'': a brass cart going east at maximum roller speed (50k) was chased by a high-speed (~120k) wooden cart, also going east. When the wooden cart caught up with the metal cart and pushed it, the wooden cart stopped and the brass cart slowed down to about 7k.
+
But
 +
2a. any potential speed of the pushed cart in the same direction is lost without a trace: a brass cart going east at maximum roller speed (50k) was chased by a high-speed (~120k) wooden cart, also going east. When the wooden cart caught up with the metal cart and pushed it, the wooden cart stopped and the brass cart slowed down to about 7k.
  
 
2b) any cargo inside the carts prior to the collision will be factored into the momentum/speed calculation. Any shooting of the cargo effectively takes place after the collision.  
 
2b) any cargo inside the carts prior to the collision will be factored into the momentum/speed calculation. Any shooting of the cargo effectively takes place after the collision.  
Line 17: Line 15:
 
:Addendum: when a cart going northeast pushes a cart going southeast, that cart will move off towards the northeast. Vectors are not combined, momentum just gets moved from the former to the new holder.
 
:Addendum: when a cart going northeast pushes a cart going southeast, that cart will move off towards the northeast. Vectors are not combined, momentum just gets moved from the former to the new holder.
  
4. if two carts attempt to move into the same tile on the same turn, build order of the carts decides which one enters the tile first. See below.
+
4. if two carts attempt to move into the same tile on the same turn, build order of the carts decides which one enters the tile first. I think it's last-built cart moves first, as with other build order checks, but haven't tested this recently. As a consequence, if two carts approach each other from opposite directions, trying to enter the collision tile on the same step, the "younger" cart will move off in the older cart's movement direction, with that cart's momentum, while the older cart simply stops. A precisely calibrated circuit doing this could sort minecarts by build order.
  
 
==The collision speed cap, applications and exceptions==
 
==The collision speed cap, applications and exceptions==

Please note that all contributions to Dwarf Fortress Wiki are considered to be released under the GFDL & MIT (see Dwarf Fortress Wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following CAPTCHA:

Cancel Editing help (opens in new window)

Templates used on this page: