CleverRaven/Cataclysm-DDA — pull request #1489 by yobbobanana (2013-06-08 16:35:17+00:00)
Title: Make movement take half the cost of both the beginning and end tiles,

in stead of just taking the cost of the end tile.

Solves the asymmetry issue discussed in #1435. Also makes the general exploit of kiting zombies into rough terrain then bashing them with impunity less effective, as the movement penalty is spread between the terrain types entered and exited.

The player side was straightforward, but monster movement had all sorts of weird issues, some of which I'm fairly certain were bugs.

There was a blanket "moves -= 100" being applied for monsters, which sometimes got applied twice for no reason, and made calculating diagonal movement costs freaking annoying, so i shunted it around into more sensible places.

I'm pretty sure I covered all code routes, but if games randomly start freezing, well this commit is probably the culprit.