summaryrefslogtreecommitdiff
path: root/src/wizard2.c
diff options
context:
space:
mode:
authorBardur Arantsson <bardur@scientician.net>2012-04-19 23:11:34 +0200
committerBardur Arantsson <bardur@scientician.net>2012-04-19 23:11:42 +0200
commit4743b501f48b257b32defb201c35ec05cf7feaa9 (patch)
tree5e47e9cf73aa86541abd2da0249a5c8dfa53c0b3 /src/wizard2.c
parent1cd265d4f32d2c624387b1bafc45ed0d18b3d257 (diff)
Add option to edit piety in wizard mode.
Diffstat (limited to 'src/wizard2.c')
-rw-r--r--src/wizard2.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/wizard2.c b/src/wizard2.c
index 36efa148..e2683435 100644
--- a/src/wizard2.c
+++ b/src/wizard2.c
@@ -351,6 +351,23 @@ static void do_cmd_wiz_change_aux(void)
/* Update */
check_experience();
+
+ /* Default */
+ sprintf(tmp_val, "%ld", (long) (p_ptr->grace));
+
+ /* Query */
+ if (!get_string("Piety: ", tmp_val, 9)) return;
+
+ /* Extract */
+ tmp_long = atol(tmp_val);
+
+ /* Verify */
+ if (tmp_long < 0) tmp_long = 0L;
+
+ /* Save */
+ p_ptr->grace = tmp_long;
+
+
/* Default */
sprintf(tmp_val, "%d", p_ptr->luck_base);