2013 Deskull rearranged comment for Doxygen.
*/
-#include "angband.h"
-#include "core.h"
-#include "util.h"
+#include "system/angband.h"
+#include "core/stuff-handler.h"
+#include "util/util.h"
+#include "main/sound-definitions-table.h"
#include "cmd/cmd-spell.h"
#include "io/write-diary.h"
#include "cmd/cmd-dump.h"
-#include "selfinfo.h"
-#include "spells.h"
-#include "spells-summon.h"
-#include "realm-hex.h"
-#include "mind.h"
-#include "avatar.h"
-#include "player-damage.h"
-#include "player-status.h"
-#include "player-effects.h"
-#include "player-skill.h"
-#include "player-class.h"
-#include "player-inventory.h"
-#include "object-hook.h"
+#include "player/selfinfo.h"
+#include "spell/technic-info-table.h"
+#include "spell/spells2.h"
+#include "spell/spells3.h"
+#include "spell/spells-summon.h"
+#include "realm/realm-hex.h"
+#include "mind/mind.h"
+#include "player/avatar.h"
+#include "player/player-damage.h"
+#include "player/player-status.h"
+#include "player/player-effects.h"
+#include "player/player-skill.h"
+#include "player/player-class.h"
+#include "inventory/player-inventory.h"
+#include "object/object-hook.h"
#include "cmd-basic.h"
-#include "view-mainwindow.h"
-#include "floor.h"
-#include "autopick.h"
-#include "japanese.h"
+#include "view/display-main-window.h"
+#include "floor/floor.h"
+#include "autopick/autopick-reader-writer.h"
+#include "locale/japanese.h"
+#include "spell/spells-util.h"
+#include "spell/spells-execution.h"
/*!
* 魔法領域フラグ管理テーブル /
object_type *o_ptr;
concptr q, s;
+ OBJECT_TYPE_VALUE tval = 0;
/* Warriors are illiterate */
if (!(caster_ptr->realm1 || caster_ptr->realm2) && (caster_ptr->pclass != CLASS_SORCERER) && (caster_ptr->pclass != CLASS_RED_MAGE))
}
/* Restrict choices to "useful" books */
- if (caster_ptr->realm2 == REALM_NONE) item_tester_tval = mp_ptr->spell_book;
+ if (caster_ptr->realm2 == REALM_NONE) tval = mp_ptr->spell_book;
else item_tester_hook = item_tester_learn_spell;
q = _("どの本を読みますか? ", "Browse which book? ");
s = _("読める本がない。", "You have no books that you can read.");
- o_ptr = choose_object(caster_ptr, &item, q, s, (USE_INVEN | USE_FLOOR | (caster_ptr->pclass == CLASS_FORCETRAINER ? USE_FORCE : 0)), item_tester_tval);
+ o_ptr = choose_object(caster_ptr, &item, q, s, (USE_INVEN | USE_FLOOR | (caster_ptr->pclass == CLASS_FORCETRAINER ? USE_FORCE : 0)), tval);
+
+ item_tester_hook = NULL;
if (!o_ptr)
{
if (item == INVEN_FORCE) /* the_force */
caster_ptr->spell_worked2 = 0L;
caster_ptr->spell_forgotten2 = 0L;
- sprintf(tmp, _("魔法の領域を%sから%sに変更した。", "change magic realm from %s to %s."), realm_names[caster_ptr->realm2], realm_names[next_realm]);
+ sprintf(tmp, _("魔法の領域を%sから%sに変更した。", "changed magic realm from %s to %s."), realm_names[caster_ptr->realm2], realm_names[next_realm]);
exe_write_diary(caster_ptr, DIARY_DESCRIPTION, 0, tmp);
caster_ptr->old_realm |= 1 << (caster_ptr->realm2 - 1);
caster_ptr->realm2 = next_realm;
concptr p = spell_category_name(mp_ptr->spell_book);
object_type *o_ptr;
concptr q, s;
+ OBJECT_TYPE_VALUE tval = 0;
+
if (!caster_ptr->realm1)
{
/* Restrict choices to "useful" books */
- if (caster_ptr->realm2 == REALM_NONE) item_tester_tval = mp_ptr->spell_book;
+ if (caster_ptr->realm2 == REALM_NONE) tval = mp_ptr->spell_book;
else item_tester_hook = item_tester_learn_spell;
q = _("どの本から学びますか? ", "Study which book? ");
s = _("読める本がない。", "You have no books that you can read.");
- o_ptr = choose_object(caster_ptr, &item, q, s, (USE_INVEN | USE_FLOOR), item_tester_tval);
+ o_ptr = choose_object(caster_ptr, &item, q, s, (USE_INVEN | USE_FLOOR), tval);
- item_tester_tval = 0;
if (!o_ptr) return;
/* Access the item's sval */