#include "view-mainwindow.h"
#include "player-class.h"
#include "player-personality.h"
+#include "world.h"
/*
* The artifact arrays
random_slay(o_ptr);
break;
default:
- if (p_ptr->wizard) msg_print("Switch error in become_random_artifact!");
+ if (current_world_ptr->wizard) msg_print("Switch error in become_random_artifact!");
powers++;
}
};
/* Assume no cheating */
creature_ptr->noscore = 0;
- creature_ptr->wizard = FALSE;
+ current_world_ptr->wizard = FALSE;
/* Not waiting to report score */
creature_ptr->wait_report_score = FALSE;
}
else
{
- if (!p_ptr->wizard)
+ if (!current_world_ptr->wizard)
{
/* Skip non-flavoured objects */
if (!k_ptr->flavor) continue;
/* Hack -- visual_list mode */
if (per_page == 1)
{
- c_prt(attr, format("%02x/%02x", r_ptr->x_attr, r_ptr->x_char), row + i, (p_ptr->wizard || visual_only) ? 56 : 61);
+ c_prt(attr, format("%02x/%02x", r_ptr->x_attr, r_ptr->x_char), row + i, (current_world_ptr->wizard || visual_only) ? 56 : 61);
}
- if (p_ptr->wizard || visual_only)
+ if (current_world_ptr->wizard || visual_only)
{
c_prt(attr, format("%d", r_idx), row + i, 62);
}
prt(format(_("%s - モンスター", "%s - monsters"), !visual_only ? _("知識", "Knowledge") : _("表示", "Visuals")), 2, 0);
if (direct_r_idx < 0) prt(_("グループ", "Group"), 4, 0);
prt(_("名前", "Name"), 4, max + 3);
- if (p_ptr->wizard || visual_only) prt("Idx", 4, 62);
+ if (current_world_ptr->wizard || visual_only) prt("Idx", 4, 62);
prt(_("文字", "Sym"), 4, 67);
if (!visual_only) prt(_("殺害数", "Kills"), 4, 72);
/* Hack -- visual_list mode */
if (per_page == 1)
{
- c_prt(attr, format("%02x/%02x", flavor_k_ptr->x_attr, flavor_k_ptr->x_char), row + i, (p_ptr->wizard || visual_only) ? 64 : 68);
+ c_prt(attr, format("%02x/%02x", flavor_k_ptr->x_attr, flavor_k_ptr->x_char), row + i, (current_world_ptr->wizard || visual_only) ? 64 : 68);
}
- if (p_ptr->wizard || visual_only)
+ if (current_world_ptr->wizard || visual_only)
{
c_prt(attr, format("%d", k_idx), row + i, 70);
}
prt(format("%s - アイテム", !visual_only ? "知識" : "表示"), 2, 0);
if (direct_k_idx < 0) prt("グループ", 4, 0);
prt("名前", 4, max + 3);
- if (p_ptr->wizard || visual_only) prt("Idx", 4, 70);
+ if (current_world_ptr->wizard || visual_only) prt("Idx", 4, 70);
prt("文字", 4, 74);
#else
prt(format("%s - objects", !visual_only ? "Knowledge" : "Visuals"), 2, 0);
if (direct_k_idx < 0) prt("Group", 4, 0);
prt("Name", 4, max + 3);
- if (p_ptr->wizard || visual_only) prt("Idx", 4, 70);
+ if (current_world_ptr->wizard || visual_only) prt("Idx", 4, 70);
prt("Sym", 4, 75);
#endif
/* Display lighting level */
c_prt(attr, format("(%s)", lighting_level_str[lighting_level]), row_i, col + 1 + strlen(f_name + f_ptr->name));
- c_prt(attr, format("%02x/%02x", f_ptr->x_attr[lighting_level], f_ptr->x_char[lighting_level]), row_i, f_idx_col - ((p_ptr->wizard || visual_only) ? 6 : 2));
+ c_prt(attr, format("%02x/%02x", f_ptr->x_attr[lighting_level], f_ptr->x_char[lighting_level]), row_i, f_idx_col - ((current_world_ptr->wizard || visual_only) ? 6 : 2));
}
- if (p_ptr->wizard || visual_only)
+ if (current_world_ptr->wizard || visual_only)
{
c_prt(attr, format("%d", f_idx), row_i, f_idx_col);
}
prt(_("名前", "Name"), 4, max + 3);
if (use_bigtile)
{
- if (p_ptr->wizard || visual_only) prt("Idx", 4, 62);
+ if (current_world_ptr->wizard || visual_only) prt("Idx", 4, 62);
prt(_("文字 ( l/ d)", "Sym ( l/ d)"), 4, 66);
}
else
{
- if (p_ptr->wizard || visual_only) prt("Idx", 4, 64);
+ if (current_world_ptr->wizard || visual_only) prt("Idx", 4, 64);
prt(_("文字 (l/d)", "Sym (l/d)"), 4, 68);
}
do_cmd_knowledge_quests_completed(fff, quest_num);
fputc('\n', fff);
do_cmd_knowledge_quests_failed(fff, quest_num);
- if (p_ptr->wizard)
+ if (current_world_ptr->wizard)
{
fputc('\n', fff);
do_cmd_knowledge_quests_wiz_random(fff);
case 'b':
{
/* Spawn */
- do_cmd_options_aux(OPT_PAGE_BIRTH, (!p_ptr->wizard || !allow_debug_opts) ?
+ do_cmd_options_aux(OPT_PAGE_BIRTH, (!current_world_ptr->wizard || !allow_debug_opts) ?
_("初期オプション(参照のみ)", "Birth Options(browse only)") :
_("初期オプション((*)はスコアに影響)", "Birth Options((*)s effect score)"));
break;
int opt[24];
char buf[80];
bool browse_only = (page == OPT_PAGE_BIRTH) && current_world_ptr->character_generated &&
- (!p_ptr->wizard || !allow_debug_opts);
+ (!current_world_ptr->wizard || !allow_debug_opts);
/* Lookup the options */
{
old_ptr = ma_ptr;
- if (p_ptr->wizard && cheat_xtra)
+ if (current_world_ptr->wizard && cheat_xtra)
{
msg_print(_("攻撃を再選択しました。", "Attack re-selected."));
}
/*** Wizard Commands ***/
case KTRL('W'):
{
- if (p_ptr->wizard)
+ if (current_world_ptr->wizard)
{
- p_ptr->wizard = FALSE;
+ current_world_ptr->wizard = FALSE;
msg_print(_("ウィザードモード解除。", "Wizard mode off."));
}
else if (enter_wizard_mode())
{
- p_ptr->wizard = TRUE;
+ current_world_ptr->wizard = TRUE;
msg_print(_("ウィザードモード突入。", "Wizard mode on."));
}
p_ptr->update |= (PU_MONSTERS);
{
if (enter_wizard_mode())
{
- p_ptr->wizard = TRUE;
+ current_world_ptr->wizard = TRUE;
if (p_ptr->is_dead || !p_ptr->y || !p_ptr->x)
{
else
{
/* Mega-Hack -- Allow player to cheat death */
- if ((p_ptr->wizard || cheat_live) && !get_check(_("死にますか? ", "Die? ")))
+ if ((current_world_ptr->wizard || cheat_live) && !get_check(_("死にますか? ", "Die? ")))
{
cheat_death(p_ptr);
}
int ob = option_info[i].o_bit;
if ((p_ptr->playing || current_world_ptr->character_xtra) &&
- (OPT_PAGE_BIRTH == option_info[i].o_page) && !p_ptr->wizard)
+ (OPT_PAGE_BIRTH == option_info[i].o_page) && !current_world_ptr->wizard)
{
msg_format(_("初期オプションは変更できません! '%s'", "Birth options can not changed! '%s'"), buf);
msg_print(NULL);
rd_u16b(&c);
- if (c & 0x0002) p_ptr->wizard = TRUE;
+ if (c & 0x0002) current_world_ptr->wizard = TRUE;
cheat_peek = (c & 0x0100) ? TRUE : FALSE;
cheat_hear = (c & 0x0200) ? TRUE : FALSE;
if (m_ptr->dealt_damage > m_ptr->max_maxhp * 100) m_ptr->dealt_damage = m_ptr->max_maxhp * 100;
- if (p_ptr->wizard)
+ if (current_world_ptr->wizard)
{
msg_format(_("合計%d/%dのダメージを与えた。", "You do %d (out of %d) damage."), m_ptr->dealt_damage, m_ptr->maxhp);
}
Term_addstr(-1, TERM_WHITE, "'):");
/* Wizards get extra info */
- if (p_ptr->wizard)
+ if (current_world_ptr->wizard)
{
char buf[16];
chance = r_ptr->artifact_percent[i];
}
- if ((a_idx > 0) && ((randint0(100) < chance) || p_ptr->wizard))
+ if ((a_idx > 0) && ((randint0(100) < chance) || current_world_ptr->wizard))
{
artifact_type *a_ptr = &a_info[a_idx];
#else
msg_format("The %s disappear%s.", o_name, (plural ? "" : "s"));
#endif
- if (p_ptr->wizard) msg_print(_("(破損)", "(breakage)"));
+ if (current_world_ptr->wizard) msg_print(_("(破損)", "(breakage)"));
/* Failure */
return (0);
msg_format("The %s disappear%s.", o_name, (plural ? "" : "s"));
#endif
- if (p_ptr->wizard) msg_print(_("(床スペースがない)", "(no floor space)"));
+ if (current_world_ptr->wizard) msg_print(_("(床スペースがない)", "(no floor space)"));
/* Failure */
return (0);
msg_format("The %s disappear%s.", o_name, (plural ? "" : "s"));
#endif
- if (p_ptr->wizard) msg_print(_("(床スペースがない)", "(no floor space)"));
+ if (current_world_ptr->wizard) msg_print(_("(床スペースがない)", "(no floor space)"));
/* Mega-Hack -- preserve artifacts */
if (preserve_mode)
msg_format("The %s disappear%s.", o_name, (plural ? "" : "s"));
#endif
- if (p_ptr->wizard) msg_print(_("(アイテムが多過ぎる)", "(too many objects)"));
+ if (current_world_ptr->wizard) msg_print(_("(アイテムが多過ぎる)", "(too many objects)"));
/* Hack -- Preserve artifacts */
if (object_is_fixed_artifact(j_ptr))
ok_move = PATTERN_TILE_1;
break;
default:
- if (creature_ptr->wizard)
+ if (current_world_ptr->wizard)
msg_format(_("おかしなパターン歩行、%d。", "Funny Pattern walking, %d."), pattern_type_cur);
return TRUE; /* Goof-up */
/* Demon characters are unaffected */
if (PRACE_IS_(creature_ptr, RACE_IMP) || PRACE_IS_(creature_ptr, RACE_DEMON) || (mimic_info[creature_ptr->mimic_form].MIMIC_FLAGS & MIMIC_IS_DEMON)) return;
- if (creature_ptr->wizard) return;
+ if (current_world_ptr->wizard) return;
/* Undead characters are 50% likely to be unaffected */
if (PRACE_IS_(creature_ptr, RACE_SKELETON) || PRACE_IS_(creature_ptr, RACE_ZOMBIE)
bool reset_concent; /* Concentration reset flag */
- bool wizard; /* Player is in wizard mode */
-
MONSTER_IDX riding; /* Riding on a monster of this index */
#define KNOW_STAT 0x01
#include "targeting.h"
#include "realm-song.h"
#include "view-mainwindow.h"
+#include "world.h"
#define MAX_KEEP 4 /*!<呪術の最大詠唱数 */
project(0, rad, caster_ptr->y, caster_ptr->x, power, GF_HELL_FIRE,
(PROJECT_STOP | PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL), -1);
}
- if (caster_ptr->wizard)
+ if (current_world_ptr->wizard)
{
msg_format(_("%d点のダメージを返した。", "You return %d damages."), power);
}
fire_ball(GF_HELL_FIRE, dir, power, 1);
- if (caster_ptr->wizard)
+ if (current_world_ptr->wizard)
{
msg_format(_("%d点のダメージを返した。", "You return %d damages."), power);
}
c = 0;
- if (p_ptr->wizard) c |= 0x0002;
+ if (current_world_ptr->wizard) c |= 0x0002;
if (cheat_sight) c |= 0x0040;
if (cheat_turn) c |= 0x0080;
}
/* Accept any grid when wizard mode */
- if (p_ptr->wizard && !(mode & TELEPORT_PASSIVE) && (!current_floor_ptr->grid_array[y][x].m_idx || (current_floor_ptr->grid_array[y][x].m_idx == p_ptr->riding))) break;
+ if (current_world_ptr->wizard && !(mode & TELEPORT_PASSIVE) && (!current_floor_ptr->grid_array[y][x].m_idx || (current_floor_ptr->grid_array[y][x].m_idx == p_ptr->riding))) break;
/* Accept teleportable floor grids */
if (cave_player_teleportable_bold(y, x, mode)) break;
if (randint0(100) < 50) go_up = TRUE;
else go_up = FALSE;
- if ((m_idx <= 0) && p_ptr->wizard)
+ if ((m_idx <= 0) && current_world_ptr->wizard)
{
if (get_check("Force to go up? ")) go_up = TRUE;
else if (get_check("Force to go down? ")) go_up = FALSE;
char buf[256];
bool max = FALSE;
- if (((use_realm <= REALM_NONE) || (use_realm > MAX_REALM)) && p_ptr->wizard)
+ if (((use_realm <= REALM_NONE) || (use_realm > MAX_REALM)) && current_world_ptr->wizard)
msg_print(_("警告! print_spell が領域なしに呼ばれた", "Warning! print_spells called with null realm"));
/* Title the list */
#include "quest.h"
#include "dungeon.h"
#include "spells.h"
+#include "world.h"
/*!
* @brief コンソール上におけるマップ表示の左上位置を返す /
}
else if (!ap_r_ptr->r_tkills || (m_ptr->mflag2 & MFLAG2_KAGE))
{
- if (!p_ptr->wizard)
+ if (!current_world_ptr->wizard)
{
sprintf(buf,"??");
return;
#endif
/* Display a message */
- if (p_ptr->wizard)
+ if (current_world_ptr->wizard)
{
char f_idx_str[32];
if (g_ptr->mimic) sprintf(f_idx_str, "%d/%d", g_ptr->feat, g_ptr->mimic);
concptr p = "";
GAME_TEXT str[14];
- if (p_ptr->wizard)
+ if (current_world_ptr->wizard)
{
p = _("[ウィザード]", "[=-WIZARD-=]");
}
*/
static void prt_hunger(void)
{
- if(p_ptr->wizard && p_ptr->inside_arena) return;
+ if(current_world_ptr->wizard && p_ptr->inside_arena) return;
/* Fainting / Starving */
if (p_ptr->food < PY_FOOD_FAINT)
m_ptr = ¤t_floor_ptr->m_list[health_who];
- if (p_ptr->wizard && p_ptr->phase_out)
+ if (current_world_ptr->wizard && p_ptr->phase_out)
{
row = ROW_INFO - 2;
col = COL_INFO + 2;
bool creating_savefile; /* New savefile is currently created */
+ bool wizard; /* This world under wizard mode */
+
} world_type;
extern bool is_daytime(void);
extern void extract_day_hour_min(int *day, int *hour, int *min);
-extern world_type *current_world_ptr;
\ No newline at end of file
+extern world_type *current_world_ptr;