*/
#include "angband.h"
+#include "cmd-pet.h"
#include "grid.h"
#include "trap.h"
#include "monsterrace-hook.h"
/* Player touches it */
o_ptr->marked |= OM_TOUCHED;
-
- /* Combine / Reorder the pack (later) */
p_ptr->update |= (PU_COMBINE | PU_REORDER);
p_ptr->window |= (PW_INVEN | PW_EQUIP | PW_PLAYER);
stasis_monsters(p_ptr->lev * 4);
return TRUE;
}
+
+bool rodeo(player_type *creature_ptr)
+{
+ GAME_TEXT m_name[MAX_NLEN];
+ monster_type *m_ptr;
+ monster_race *r_ptr;
+ int rlev;
+
+ if (creature_ptr->riding)
+ {
+ msg_print(_("今は乗馬中だ。", "You ARE riding."));
+ return FALSE;
+ }
+ if (!do_riding(TRUE)) return TRUE;
+
+ m_ptr = &m_list[creature_ptr->riding];
+ r_ptr = &r_info[m_ptr->r_idx];
+ monster_desc(m_name, m_ptr, 0);
+ msg_format(_("%sに乗った。", "You ride on %s."), m_name);
+
+ if (is_pet(m_ptr)) return TRUE;
+
+ rlev = r_ptr->level;
+
+ if (r_ptr->flags1 & RF1_UNIQUE) rlev = rlev * 3 / 2;
+ if (rlev > 60) rlev = 60 + (rlev - 60) / 2;
+ if ((randint1(creature_ptr->skill_exp[GINOU_RIDING] / 120 + creature_ptr->lev * 2 / 3) > rlev)
+ && one_in_(2) && !creature_ptr->inside_arena && !creature_ptr->inside_battle
+ && !(r_ptr->flags7 & (RF7_GUARDIAN)) && !(r_ptr->flags1 & (RF1_QUESTOR))
+ && (rlev < creature_ptr->lev * 3 / 2 + randint0(creature_ptr->lev / 5)))
+ {
+ msg_format(_("%sを手なずけた。", "You tame %s."), m_name);
+ set_pet(m_ptr);
+ }
+ else
+ {
+ msg_format(_("%sに振り落とされた!", "You have thrown off by %s."), m_name);
+ rakuba(1, TRUE);
+
+ /* Paranoia */
+ /* 落馬処理に失敗してもとにかく乗馬解除 */
+ creature_ptr->riding = 0;
+ }
+ return TRUE;
+}
+
+bool clear_mind(player_type *creature_ptr)
+{
+ if (total_friends)
+ {
+ msg_print(_("今はペットを操ることに集中していないと。", "You need concentration on the pets now."));
+ return FALSE;
+ }
+ msg_print(_("少し頭がハッキリした。", "You feel your head clear a little."));
+
+ creature_ptr->csp += (3 + creature_ptr->lev / 20);
+ if (creature_ptr->csp >= creature_ptr->msp)
+ {
+ creature_ptr->csp = creature_ptr->msp;
+ creature_ptr->csp_frac = 0;
+ }
+ creature_ptr->redraw |= (PR_MANA);
+ return TRUE;
+}
+
+bool concentration(player_type *creature_ptr)
+{
+ int max_csp = MAX(creature_ptr->msp * 4, creature_ptr->lev * 5 + 5);
+
+ if (total_friends)
+ {
+ msg_print(_("今はペットを操ることに集中していないと。", "You need concentration on the pets now."));
+ return FALSE;
+ }
+ if (creature_ptr->special_defense & KATA_MASK)
+ {
+ msg_print(_("今は構えに集中している。", "You need concentration on your form."));
+ return FALSE;
+ }
+ msg_print(_("精神を集中して気合いを溜めた。", "You concentrate to charge your power."));
+
+ creature_ptr->csp += creature_ptr->msp / 2;
+ if (creature_ptr->csp >= max_csp)
+ {
+ creature_ptr->csp = max_csp;
+ creature_ptr->csp_frac = 0;
+ }
+ creature_ptr->redraw |= (PR_MANA);
+ return TRUE;
+}