summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/spl-cast.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-07-07 11:58:54 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-07-07 11:58:54 +0000
commit167ae03b160a0ccadd7934b2bfe557d491f1cb1f (patch)
treec1ee0ef626b416c5eee0f62082da72cb9f4137c3 /crawl-ref/source/spl-cast.cc
parent33dc7cedd5a65d3bd1ce8eff9006e4517a3390dd (diff)
downloadcrawl-ref-167ae03b160a0ccadd7934b2bfe557d491f1cb1f.tar.gz
crawl-ref-167ae03b160a0ccadd7934b2bfe557d491f1cb1f.zip
Another clean up, and add some new weapon speech.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6439 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/spl-cast.cc')
-rw-r--r--crawl-ref/source/spl-cast.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/crawl-ref/source/spl-cast.cc b/crawl-ref/source/spl-cast.cc
index 08e9890a99..51a3c0ff70 100644
--- a/crawl-ref/source/spl-cast.cc
+++ b/crawl-ref/source/spl-cast.cc
@@ -1100,10 +1100,10 @@ spret_type your_spells(spell_type spell, int powc, bool allow_fail)
if (you.religion == GOD_SIF_MUNA
&& !player_under_penance()
- && you.piety >= 100 && random2(150) <= you.piety)
+ && you.piety >= 100 && x_chance_in_y(you.piety + 1, 150))
{
canned_msg(MSG_NOTHING_HAPPENS);
- return SPRET_FAIL;
+ return (SPRET_FAIL);
}
unsigned int sptype = 0;
@@ -2896,8 +2896,8 @@ static void _miscast_divination(int severity, const char* cause)
static void _miscast_necromancy(int severity, const char* cause)
{
if (you.religion == GOD_KIKUBAAQUDGHA
- && (!player_under_penance() && you.piety >= piety_breakpoint(1)
- && you.piety > random2(150)))
+ && !player_under_penance() && you.piety >= piety_breakpoint(1)
+ && x_chance_in_y(you.piety, 150))
{
canned_msg(MSG_NOTHING_HAPPENS);
return;