summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/areas.cc
diff options
context:
space:
mode:
authorelliptic <hyperelliptical@gmail.com>2014-03-16 01:50:54 -0400
committerelliptic <hyperelliptical@gmail.com>2014-03-16 02:05:58 -0400
commit6a60d70b8158e6227dc6434320b820311ecff1fb (patch)
tree40b4d9fe497cc23807bc154ddb89c78e62ec1bbd /crawl-ref/source/areas.cc
parent06cfa3b5d85c0a9268ad7ed1f6a3ab3114b216e6 (diff)
downloadcrawl-ref-6a60d70b8158e6227dc6434320b820311ecff1fb.tar.gz
crawl-ref-6a60d70b8158e6227dc6434320b820311ecff1fb.zip
Tweak TSO/Dith halo/umbra radii.
The old formula had three issues: * Smallest radius was 1, meaning that orthogonally adjacent squares were in the halo but not diagonally adjacent squares. This meant that TSOites with this size halo wanted to avoid meleeing diagonally, which was awkward. * Largest radius was 8, meaning that it missed a few squares at the edge of LOS (those at distance sqrt(65)), which was ugly and confusing for stuff like Dith's shadow step ability. * Largest radius was reached at 170 piety, which was inconsistent with other god abilities (which either stop at 160 piety = ****** or go all the way to 200 piety. This commit addresses all of these issues: the smallest radius is sqrt(2), the largest radius is sqrt(65), and the largest radius is reached at 160 piety exactly. This does mean a slight increase in halo size in general, so it is a (very minor) buff to these gods.
Diffstat (limited to 'crawl-ref/source/areas.cc')
-rw-r--r--crawl-ref/source/areas.cc12
1 files changed, 4 insertions, 8 deletions
diff --git a/crawl-ref/source/areas.cc b/crawl-ref/source/areas.cc
index 72ee38e4dc..e9959402da 100644
--- a/crawl-ref/source/areas.cc
+++ b/crawl-ref/source/areas.cc
@@ -556,10 +556,8 @@ int player::halo_radius2() const
if (religion == GOD_SHINING_ONE && piety >= piety_breakpoint(0)
&& !penance[GOD_SHINING_ONE])
{
- // Preserve the middle of old radii.
- const int r = piety - 10;
- // The cap is 64, just less than the LOS of 65.
- size = min(LOS_RADIUS*LOS_RADIUS, r * r / 400);
+ // The cap is reached at piety 160 = ******.
+ size = min(LOS_RADIUS*LOS_RADIUS + 1, piety * piety / 393);
}
if (player_equip_unrand(UNRAND_BRILLIANCE))
@@ -714,10 +712,8 @@ int player::umbra_radius2() const
if (religion == GOD_DITHMENOS && piety >= piety_breakpoint(0)
&& !penance[GOD_DITHMENOS])
{
- // Preserve the middle of old radii.
- const int r = piety - 10;
- // The cap is 64, just less than the LOS of 65.
- size = min(LOS_RADIUS*LOS_RADIUS, r * r / 400);
+ // The cap is reached at piety 160 = ******.
+ size = min(LOS_RADIUS*LOS_RADIUS + 1, piety * piety / 393);
}
if (player_equip_unrand(UNRAND_SHADOWS))