Hengband
2.1.4
|
雑多なその他の処理2 / effects of various "objects" [詳解]
#include "angband.h"
マクロ定義 | |
#define | REWARD_CHANCE 10 |
#define | Go_no_JuuJou 5*5*5*5*5*5*5*5*5*5 |
関数 | |
void | check_experience (void) |
プレイヤーの経験値について整合性のためのチェックと調整を行う / Advance experience levels and print experience [詳解] | |
static int | get_coin_type (int r_idx) |
モンスターを倒した際の財宝svalを返す [詳解] | |
static bool | kind_is_cloak (int k_idx) |
オブジェクトがクロークかどうかを判定する / Hack – determine if a template is Cloak [詳解] | |
static bool | kind_is_polearm (int k_idx) |
オブジェクトが竿状武器かどうかを判定する / Hack – determine if a template is Polearm [詳解] | |
static bool | kind_is_sword (int k_idx) |
オブジェクトが剣かどうかを判定する / Hack – determine if a template is Sword [詳解] | |
static bool | kind_is_book (int k_idx) |
オブジェクトが魔法書かどうかを判定する / Hack – determine if a template is Book [詳解] | |
static bool | kind_is_good_book (int k_idx) |
オブジェクトがベースアイテム時点でGOODかどうかを判定する / Hack – determine if a template is Good book [詳解] | |
static bool | kind_is_armor (int k_idx) |
オブジェクトが鎧かどうかを判定する / Hack – determine if a template is Armor [詳解] | |
static bool | kind_is_hafted (int k_idx) |
オブジェクトが打撃武器かどうかを判定する / Hack – determine if a template is hafted weapon [詳解] | |
void | complete_quest (int quest_num) |
クエストを達成状態にする / [詳解] | |
static int | count_all_hostile_monsters (void) |
現在フロアに残っている敵モンスターの数を返す / [詳解] | |
void | check_quest_completion (monster_type *m_ptr) |
特定の敵を倒した際にクエスト達成処理 / Check for "Quest" completion when a quest monster is killed or charmed. [詳解] | |
void | check_find_art_quest_completion (object_type *o_ptr) |
特定のアーティファクトを入手した際のクエスト達成処理 / Check for "Quest" completion when a quest monster is killed or charmed. [詳解] | |
cptr | extract_note_dies (monster_race *r_ptr) |
モンスターを撃破した際の述語メッセージを返す / Return monster death string [詳解] | |
void | monster_death (int m_idx, bool drop_item) |
モンスターが死亡した時の処理 / Handle the "death" of a monster. [詳解] | |
int | mon_damage_mod (monster_type *m_ptr, int dam, bool is_psy_spear) |
モンスターに与えたダメージの修正処理 / Modify the physical damage done to the monster. [詳解] | |
static void | get_exp_from_mon (int dam, monster_type *m_ptr) |
モンスターに与えたダメージを元に経験値を加算する / Calculate experience point to be get [詳解] | |
bool | mon_take_hit (int m_idx, int dam, bool *fear, cptr note) |
モンスターのHPをダメージに応じて減算する / Decreases monsters hit points, handling monster death. [詳解] | |
void | get_screen_size (int *wid_p, int *hgt_p) |
現在のコンソール表示の縦横を返す。 / Get term size and calculate screen size [詳解] | |
void | panel_bounds_center (void) |
コンソール上におけるマップ表示の左上位置を返す / Calculates current boundaries Called below and from "do_cmd_locate()". [詳解] | |
void | resize_map (void) |
コンソールのリサイズに合わせてマップを再描画する / Map resizing whenever the main term changes size [詳解] | |
void | redraw_window (void) |
コンソールを再描画する / Redraw a term when it is resized [詳解] | |
bool | change_panel (int dy, int dx) |
フォーカスを当てるべきマップ描画の基準座標を指定する(サブルーチン) [詳解] | |
bool | change_panel_xy (int y, int x) |
フォーカスを当てるべきマップ描画の基準座標を指定する [詳解] | |
void | verify_panel (void) |
マップ描画のフォーカスを当てるべき座標を更新する [詳解] | |
cptr | look_mon_desc (monster_type *m_ptr, u32b mode) |
void | ang_sort_aux (vptr u, vptr v, int p, int q) |
void | ang_sort (vptr u, vptr v, int n) |
bool | target_able (int m_idx) |
bool | target_okay (void) |
static bool | ang_sort_comp_distance (vptr u, vptr v, int a, int b) |
static bool | ang_sort_comp_importance (vptr u, vptr v, int a, int b) |
static void | ang_sort_swap_distance (vptr u, vptr v, int a, int b) |
static s16b | target_pick (int y1, int x1, int dy, int dx) |
static bool | target_set_accept (int y, int x) |
static void | target_set_prepare (int mode) |
void | target_set_prepare_look () |
static void | evaluate_monster_exp (char *buf, monster_type *m_ptr) |
static int | target_set_aux (int y, int x, int mode, cptr info) |
bool | target_set (int mode) |
bool | get_aim_dir (int *dp) |
bool | get_rep_dir (int *dp, bool under) |
bool | get_rep_dir2 (int *dp) |
void | gain_level_reward (int chosen_reward) |
static bool | tgt_pt_accept (int y, int x) |
static void | tgt_pt_prepare (void) |
bool | tgt_pt (int *x_ptr, int *y_ptr) |
bool | get_hack_dir (int *dp) |
s16b | gain_energy (void) |
s16b | bow_energy (int sval) |
int | bow_tmul (int sval) |
cptr | your_alignment (void) |
int | weapon_exp_level (int weapon_exp) |
int | riding_exp_level (int riding_exp) |
int | spell_exp_level (int spell_exp) |
int | rumor_num (char *zz, int max_idx) |
cptr | rumor_bind_name (char *base, cptr fullname) |
void | display_rumor (bool ex) |
変数 | |
bool | show_gold_on_floor = FALSE |
雑多なその他の処理2 / effects of various "objects"
#define Go_no_JuuJou 5*5*5*5*5*5*5*5*5*5 |
#define REWARD_CHANCE 10 |
s16b bow_energy | ( | int | sval | ) |
int bow_tmul | ( | int | sval | ) |
bool change_panel | ( | int | dy, |
int | dx | ||
) |
フォーカスを当てるべきマップ描画の基準座標を指定する(サブルーチン)
dy | 変更先のフロアY座標 |
dx | 変更先のフロアX座標 Handle a request to change the current panel Return TRUE if the panel was changed. Also used in do_cmd_locate |
bool change_panel_xy | ( | int | y, |
int | x | ||
) |
フォーカスを当てるべきマップ描画の基準座標を指定する
y | 変更先のフロアY座標 |
x | 変更先のフロアX座標 |
Handle a request to change the current panel Return TRUE if the panel was changed. Also used in do_cmd_locate
void check_experience | ( | void | ) |
プレイヤーの経験値について整合性のためのチェックと調整を行う / Advance experience levels and print experience
void check_find_art_quest_completion | ( | object_type * | o_ptr | ) |
特定のアーティファクトを入手した際のクエスト達成処理 / Check for "Quest" completion when a quest monster is killed or charmed.
o_ptr | 入手したオブジェクトの構造体参照ポインタ |
void check_quest_completion | ( | monster_type * | m_ptr | ) |
特定の敵を倒した際にクエスト達成処理 / Check for "Quest" completion when a quest monster is killed or charmed.
m_ptr | 撃破したモンスターの構造体参照ポインタ |
void complete_quest | ( | int | quest_num | ) |
クエストを達成状態にする /
quest_num | 達成状態にしたいクエストのID |
|
static |
現在フロアに残っている敵モンスターの数を返す /
void display_rumor | ( | bool | ex | ) |
|
static |
cptr extract_note_dies | ( | monster_race * | r_ptr | ) |
モンスターを撃破した際の述語メッセージを返す / Return monster death string
r_ptr | 撃破されたモンスターの種族情報を持つ構造体の参照ポインタ |
s16b gain_energy | ( | void | ) |
void gain_level_reward | ( | int | chosen_reward | ) |
bool get_aim_dir | ( | int * | dp | ) |
|
static |
モンスターを倒した際の財宝svalを返す
r_idx | 倒したモンスターの種族ID |
Hack – Return the "automatic coin type" of a monster race Used to allocate proper treasure when "Creeping coins" die XXX XXX XXX Note the use of actual "monster names"
|
static |
モンスターに与えたダメージを元に経験値を加算する / Calculate experience point to be get
dam | 与えたダメージ量 |
m_ptr | ダメージを与えたモンスターの構造体参照ポインタ |
Even the 64 bit operation is not big enough to avoid overflaw unless we carefully choose orders of multiplication and division. Get the coefficient first, and multiply (potentially huge) base experience point of a monster later.
bool get_hack_dir | ( | int * | dp | ) |
bool get_rep_dir2 | ( | int * | dp | ) |
void get_screen_size | ( | int * | wid_p, |
int * | hgt_p | ||
) |
現在のコンソール表示の縦横を返す。 / Get term size and calculate screen size
wid_p | コンソールの表示幅文字数を返す |
hgt_p | コンソールの表示行数を返す |
|
static |
オブジェクトが鎧かどうかを判定する / Hack – determine if a template is Armor
k_idx | 判定したいオブジェクトのベースアイテムID |
|
static |
オブジェクトが魔法書かどうかを判定する / Hack – determine if a template is Book
k_idx | 判定したいオブジェクトのベースアイテムID |
|
static |
オブジェクトがクロークかどうかを判定する / Hack – determine if a template is Cloak
k_idx | 判定したいオブジェクトのベースアイテムID |
|
static |
オブジェクトがベースアイテム時点でGOODかどうかを判定する / Hack – determine if a template is Good book
k_idx | 判定したいオブジェクトのベースアイテムID |
|
static |
オブジェクトが打撃武器かどうかを判定する / Hack – determine if a template is hafted weapon
k_idx | 判定したいオブジェクトのベースアイテムID |
|
static |
オブジェクトが竿状武器かどうかを判定する / Hack – determine if a template is Polearm
k_idx | 判定したいオブジェクトのベースアイテムID |
|
static |
オブジェクトが剣かどうかを判定する / Hack – determine if a template is Sword
k_idx | 判定したいオブジェクトのベースアイテムID |
cptr look_mon_desc | ( | monster_type * | m_ptr, |
u32b | mode | ||
) |
int mon_damage_mod | ( | monster_type * | m_ptr, |
int | dam, | ||
bool | is_psy_spear | ||
) |
モンスターに与えたダメージの修正処理 / Modify the physical damage done to the monster.
m_ptr | ダメージを受けるモンスターの構造体参照ポインタ |
dam | ダメージ基本値 |
is_psy_spear | 攻撃手段が光の剣ならばTRUE |
(for example when it's invulnerable or shielded) ToDo: Accept a damage-type to calculate the modified damage from things like fire, frost, lightning, poison, ... attacks. "type" is not yet used and should be 0.
モンスターのHPをダメージに応じて減算する / Decreases monsters hit points, handling monster death.
dam | 与えたダメージ量 |
m_idx | ダメージを与えたモンスターのID |
fear | ダメージによってモンスターが恐慌状態に陥ったならばTRUEを返す |
note | モンスターが倒された際の特別なメッセージ述語 |
We return TRUE if the monster has been killed (and deleted). We announce monster death (using an optional "death message" if given, and a otherwise a generic killed/destroyed message). Only "physical attacks" can induce the "You have slain" message. Missile and Spell attacks will induce the "dies" message, or various "specialized" messages. Note that "You have destroyed" and "is destroyed" are synonyms for "You have slain" and "dies". Hack -- unseen monsters yield "You have killed it." message. Added fear (DGK) and check whether to print fear messages -CWS Made name, sex, and capitalization generic -BEN- As always, the "ghost" processing is a total hack. Hack -- we "delay" fear messages by passing around a "fear" flag. XXX XXX XXX Consider decreasing monster experience over time, say, by using "(m_exp * m_lev * (m_lev)) / (p_lev * (m_lev + n_killed))" instead of simply "(m_exp * m_lev) / (p_lev)", to make the first monster worth more than subsequent monsters. This would also need to induce changes in the monster recall code.
void monster_death | ( | int | m_idx, |
bool | drop_item | ||
) |
モンスターが死亡した時の処理 / Handle the "death" of a monster.
m_idx | 死亡したモンスターのID |
drop_item | TRUEならばモンスターのドロップ処理を行う |
Disperse treasures centered at the monster location based on the various flags contained in the monster flags fields. Check for "Quest" completion when a quest monster is killed. Note that only the player can induce "monster_death()" on Uniques. Thus (for now) all Quest monsters should be Uniques. Note that monsters can now carry objects, and when a monster dies, it drops all of its objects, which may disappear in crowded rooms.
void panel_bounds_center | ( | void | ) |
コンソール上におけるマップ表示の左上位置を返す / Calculates current boundaries Called below and from "do_cmd_locate()".
void redraw_window | ( | void | ) |
コンソールを再描画する / Redraw a term when it is resized
void resize_map | ( | void | ) |
コンソールのリサイズに合わせてマップを再描画する / Map resizing whenever the main term changes size
int riding_exp_level | ( | int | riding_exp | ) |
int rumor_num | ( | char * | zz, |
int | max_idx | ||
) |
int spell_exp_level | ( | int | spell_exp | ) |
bool target_able | ( | int | m_idx | ) |
bool target_okay | ( | void | ) |
|
static |
bool target_set | ( | int | mode | ) |
|
static |
|
static |
Display list of items
|
static |
void target_set_prepare_look | ( | void | ) |
bool tgt_pt | ( | int * | x_ptr, |
int * | y_ptr | ||
) |
|
static |
|
static |
void verify_panel | ( | void | ) |
マップ描画のフォーカスを当てるべき座標を更新する
Given an row (y) and col (x), this routine detects when a move off the screen has occurred and figures new borders. -RAK- "Update" forces a "full update" to take place. The map is reprinted if necessary, and "TRUE" is returned.
int weapon_exp_level | ( | int | weapon_exp | ) |
cptr your_alignment | ( | void | ) |