Hengband
2.2.1
|
#include "angband.h"
#include "core.h"
#include "util.h"
#include "bldg.h"
#include "quest.h"
#include "player-move.h"
#include "player-status.h"
#include "player-effects.h"
#include "player-skill.h"
#include "player-race.h"
#include "player-class.h"
#include "player-personality.h"
#include "player-damage.h"
#include "floor.h"
#include "floor-events.h"
#include "feature.h"
#include "artifact.h"
#include "avatar.h"
#include "spells.h"
#include "spells-status.h"
#include "object.h"
#include "object-hook.h"
#include "object-ego.h"
#include "monster.h"
#include "monster-status.h"
#include "monsterrace-hook.h"
#include "mutation.h"
#include "patron.h"
#include "realm-hex.h"
#include "realm-song.h"
#include "cmd-pet.h"
#include "cmd-spell.h"
#include "dungeon.h"
#include "objectkind.h"
#include "monsterrace.h"
#include "autopick.h"
#include "cmd-dump.h"
#include "melee.h"
#include "world.h"
#include "view-mainwindow.h"
#include "files.h"
#include "cmd-magiceat.h"
マクロ定義 | |
#define | MAX_SAN_HORROR 20 |
恐ろしい対象の形容数(正常時) [詳解] | |
#define | MAX_SAN_FUNNY 22 |
恐ろしい対象の形容数(幻覚時) [詳解] | |
#define | MAX_SAN_COMMENT 5 |
恐ろしい対象を見たときの絶叫メッセージ数(幻覚時) [詳解] | |
関数 | |
concptr | your_alignment (player_type *creature_ptr) |
int | weapon_exp_level (int weapon_exp) |
int | riding_exp_level (int riding_exp) |
int | spell_exp_level (int spell_exp) |
void | calc_bonuses (player_type *creature_ptr) |
プレイヤーの全ステータスを更新する / Calculate the players current "state", taking into account not only race/class intrinsics, but also objects being worn and temporary spell effects. [詳解] | |
static void | calc_alignment (player_type *creature_ptr) |
static void | calc_hitpoints (player_type *creature_ptr) |
プレイヤーの最大HPを計算する / Calculate the players (maximal) hit points Adjust current hitpoints if necessary [詳解] | |
static void | calc_torch (player_type *creature_ptr) |
プレイヤーの光源半径を計算する / Extract and set the current "lite radius" [詳解] | |
static void | calc_spells (player_type *creature_ptr) |
プレイヤーの現在学習可能な魔法数を計算し、増減に応じて魔法の忘却、再学習を処置する。 / Calculate number of spells player should have, and forget, or remember, spells until that number is properly reflected. [詳解] | |
static void | calc_mana (player_type *creature_ptr) |
プレイヤーの最大MPを計算する / Calculate maximum mana. [詳解] | |
s16b | calc_num_fire (player_type *creature_ptr, object_type *o_ptr) |
装備中の射撃武器の威力倍率を返す / calcurate the fire rate of target object [詳解] | |
WEIGHT | weight_limit (player_type *creature_ptr) |
プレイヤーの所持重量制限を計算する / Computes current weight limit. [詳解] | |
bool | has_melee_weapon (player_type *creature_ptr, int i) |
プレイヤーが現在右手/左手に武器を持っているか判定する / [詳解] | |
BIT_FLAGS16 | empty_hands (player_type *creature_ptr, bool riding_control) |
プレイヤーの現在開いている手の状態を返す [詳解] | |
bool | heavy_armor (player_type *creature_ptr) |
プレイヤーが防具重量制限のある職業時にペナルティを受ける状態にあるかどうかを返す。 [詳解] | |
void | update_creature (player_type *creature_ptr) |
update のフラグに応じた更新をまとめて行う / Handle "update" [詳解] | |
bool | player_has_no_spellbooks (player_type *creature_ptr) |
プレイヤーが魔道書を一冊も持っていないかを判定する [詳解] | |
void | take_turn (player_type *creature_ptr, PERCENTAGE need_cost) |
void | free_turn (player_type *creature_ptr) |
bool | player_place (player_type *creature_ptr, POSITION y, POSITION x) |
プレイヤーを指定座標に配置する / Place the player in the dungeon XXX XXX [詳解] | |
void | wreck_the_pattern (player_type *creature_ptr) |
種族アンバライトが出血時パターンの上に乗った際のペナルティ処理 [詳解] | |
void | sanity_blast (player_type *creature_ptr, monster_type *m_ptr, bool necro) |
ELDRITCH_HORRORによるプレイヤーの精神破壊処理 [詳解] | |
void | check_experience (player_type *creature_ptr) |
プレイヤーの経験値について整合性のためのチェックと調整を行う / Advance experience levels and print experience [詳解] | |
void | cnv_stat (int val, char *out_val) |
現在の修正後能力値を3~17及び18/xxx形式に変換する / Converts stat num into a six-char (right justified) string [詳解] | |
s16b | modify_stat_value (int value, int amount) |
能力値現在値から3~17及び18/xxx様式に基づく加減算を行う。 Modify a stat value by a "modifier", return new value [詳解] | |
long | calc_score (player_type *creature_ptr) |
スコアを計算する / Hack – Calculates the total number of points earned -JWT- [詳解] | |
void | cheat_death (player_type *creature_ptr) |
変数 | |
const concptr | stat_names [6] |
能力値テーブル / Abbreviations of healthy stats [詳解] | |
const concptr | stat_names_reduced [6] |
能力値テーブル(能力低下時) / Abbreviations of damaged stats [詳解] | |
static concptr | horror_desc [MAX_SAN_HORROR] |
ELDRITCH HORROR効果時のモンスターの形容メッセージ(通常時) [詳解] | |
static concptr | funny_desc [MAX_SAN_FUNNY] |
ELDRITCH HORROR効果時のモンスターの形容メッセージ(幻覚状態時) [詳解] | |
static concptr | funny_comments [MAX_SAN_COMMENT] |
ELDRITCH HORROR効果時の幻覚時間延長を示す錯乱表現 [詳解] | |
const s32b | player_exp [PY_MAX_LEVEL] |
基本必要経験値テーブル / Base experience levels, may be adjusted up for race and/or class [詳解] | |
const s32b | player_exp_a [PY_MAX_LEVEL] |
基本必要強化値テーブル(アンドロイド専用) [詳解] | |
const byte | adj_mag_study [] |
知力/賢さによるレベル毎の習得可能魔法数テーブル Stat Table (INT/WIS) – Number of half-spells per level [詳解] | |
const byte | adj_mag_mana [] |
知力/賢さによるMP修正テーブル Stat Table (INT/WIS) – extra 1/4-mana-points per level [詳解] | |
const byte | adj_mag_fail [] |
知力/賢さによる最低魔法失敗率テーブル Stat Table (INT/WIS) – Minimum failure rate (percentage) [詳解] | |
const byte | adj_mag_stat [] |
知力/賢さによる魔法失敗率修正テーブル Stat Table (INT/WIS) – Various things [詳解] | |
const byte | adj_chr_gold [] |
魅力による店での取引修正テーブル Stat Table (CHR) – payment percentages [詳解] | |
const byte | adj_int_dev [] |
知力による魔道具使用修正テーブル Stat Table (INT) – Magic devices [詳解] | |
const byte | adj_wis_sav [] |
賢さによる魔法防御修正テーブル Stat Table (WIS) – Saving throw [詳解] | |
const byte | adj_dex_dis [] |
器用さによるトラップ解除修正テーブル Stat Table (DEX) – disarming [詳解] | |
const byte | adj_int_dis [] |
知力によるトラップ解除修正テーブル Stat Table (INT) – disarming [詳解] | |
const byte | adj_dex_ta [] |
器用さによるAC修正テーブル Stat Table (DEX) – bonus to ac (plus 128) [詳解] | |
const byte | adj_str_td [] |
腕力によるダメージ修正テーブル Stat Table (STR) – bonus to dam (plus 128) [詳解] | |
const byte | adj_dex_th [] |
器用度による命中修正テーブル Stat Table (DEX) – bonus to hit (plus 128) [詳解] | |
const byte | adj_str_th [] |
腕力による命中修正テーブル Stat Table (STR) – bonus to hit (plus 128) [詳解] | |
const byte | adj_str_wgt [] |
腕力による基本所持重量値テーブル Stat Table (STR) – weight limit in deca-pounds [詳解] | |
const byte | adj_str_hold [] |
腕力による武器重量限界値テーブル Stat Table (STR) – weapon weight limit in pounds [詳解] | |
const byte | adj_str_dig [] |
腕力による採掘能力修正値テーブル Stat Table (STR) – digging value [詳解] | |
const byte | adj_dex_safe [] |
器用さによる盗難防止&体当たり成功判定修正テーブル Stat Table (DEX) – chance of avoiding "theft" and "falling" [詳解] | |
const byte | adj_con_fix [] |
耐久による基本HP自然治癒値テーブル / Stat Table (CON) – base regeneration rate [詳解] | |
const byte | adj_con_mhp [] |
耐久による基本HP自然治癒値テーブル / Stat Table (CON) – extra 1/4-hitpoints per level (plus 128) [詳解] | |
const byte | adj_chr_chm [] |
魅力による魅了能力修正テーブル / Stat Table (CHR) – charm [詳解] | |
player_type | p_body |
player_type * | p_ptr = &p_body |
#define MAX_SAN_COMMENT 5 |
恐ろしい対象を見たときの絶叫メッセージ数(幻覚時)
#define MAX_SAN_FUNNY 22 |
恐ろしい対象の形容数(幻覚時)
#define MAX_SAN_HORROR 20 |
恐ろしい対象の形容数(正常時)
|
static |
void calc_bonuses | ( | player_type * | creature_ptr | ) |
プレイヤーの全ステータスを更新する / Calculate the players current "state", taking into account not only race/class intrinsics, but also objects being worn and temporary spell effects.
See also calc_mana() and calc_hitpoints().
Take note of the new "speed code", in particular, a very strong player will start slowing down as soon as he reaches 150 pounds, but not until he reaches 450 pounds will he be half as fast as a normal kobold. This both hurts and helps the player, hurts because in the old days a player could just avoid 300 pounds, and helps because now carrying 300 pounds is not very painful.
The "weapon" and "bow" do *not* add to the bonuses to hit or to damage, since that would affect non-combat things. These values are actually added in later, at the appropriate place.
This function induces various "status" messages.
|
static |
プレイヤーの最大HPを計算する / Calculate the players (maximal) hit points Adjust current hitpoints if necessary
|
static |
プレイヤーの最大MPを計算する / Calculate maximum mana.
You do not need to know any spells. Note that mana is lowered by heavy (or inappropriate) armor.
This function induces status messages.
s16b calc_num_fire | ( | player_type * | creature_ptr, |
object_type * | o_ptr | ||
) |
装備中の射撃武器の威力倍率を返す / calcurate the fire rate of target object
o_ptr | 計算する射撃武器のアイテム情報参照ポインタ |
long calc_score | ( | player_type * | creature_ptr | ) |
スコアを計算する / Hack – Calculates the total number of points earned -JWT-
|
static |
プレイヤーの現在学習可能な魔法数を計算し、増減に応じて魔法の忘却、再学習を処置する。 / Calculate number of spells player should have, and forget, or remember, spells until that number is properly reflected.
Note that this function induces various "status" messages, which must be bypasses until the character is created.
|
static |
プレイヤーの光源半径を計算する / Extract and set the current "lite radius"
SWD: Experimental modification: multiple light sources have additive effect.
void cheat_death | ( | player_type * | creature_ptr | ) |
void check_experience | ( | player_type * | creature_ptr | ) |
プレイヤーの経験値について整合性のためのチェックと調整を行う / Advance experience levels and print experience
void cnv_stat | ( | int | val, |
char * | out_val | ||
) |
現在の修正後能力値を3~17及び18/xxx形式に変換する / Converts stat num into a six-char (right justified) string
val | 能力値 |
out_val | 出力先文字列ポインタ |
BIT_FLAGS16 empty_hands | ( | player_type * | creature_ptr, |
bool | riding_control | ||
) |
プレイヤーの現在開いている手の状態を返す
riding_control | 乗馬中により片手を必要としている状態ならばTRUEを返す。 |
void free_turn | ( | player_type * | creature_ptr | ) |
bool has_melee_weapon | ( | player_type * | creature_ptr, |
int | i | ||
) |
プレイヤーが現在右手/左手に武器を持っているか判定する /
i | 判定する手のID(右手:0 左手:1) |
bool heavy_armor | ( | player_type * | creature_ptr | ) |
プレイヤーが防具重量制限のある職業時にペナルティを受ける状態にあるかどうかを返す。
s16b modify_stat_value | ( | int | value, |
int | amount | ||
) |
能力値現在値から3~17及び18/xxx様式に基づく加減算を行う。 Modify a stat value by a "modifier", return new value
value | 現在値 |
amount | 加減算値 |
Stats go up: 3,4,...,17,18,18/10,18/20,...,18/220 Or even: 18/13, 18/23, 18/33, ..., 18/220 Stats go down: 18/220, 18/210,..., 18/10, 18, 17, ..., 3 Or even: 18/13, 18/03, 18, 17, ..., 3
bool player_has_no_spellbooks | ( | player_type * | creature_ptr | ) |
プレイヤーが魔道書を一冊も持っていないかを判定する
bool player_place | ( | player_type * | creature_ptr, |
POSITION | y, | ||
POSITION | x | ||
) |
プレイヤーを指定座標に配置する / Place the player in the dungeon XXX XXX
x | 配置先X座標 |
y | 配置先Y座標 |
int riding_exp_level | ( | int | riding_exp | ) |
void sanity_blast | ( | player_type * | creature_ptr, |
monster_type * | m_ptr, | ||
bool | necro | ||
) |
ELDRITCH_HORRORによるプレイヤーの精神破壊処理
m_ptr | ELDRITCH_HORRORを引き起こしたモンスターの参照ポインタ |
necro | 暗黒領域魔法の詠唱失敗によるものならばTRUEを返す |
int spell_exp_level | ( | int | spell_exp | ) |
void take_turn | ( | player_type * | creature_ptr, |
PERCENTAGE | need_cost | ||
) |
void update_creature | ( | player_type * | creature_ptr | ) |
update のフラグに応じた更新をまとめて行う / Handle "update"
更新処理の対象はプレイヤーの能力修正/光源寿命/HP/MP/魔法の学習状態、他多数の外界の状態判定。
int weapon_exp_level | ( | int | weapon_exp | ) |
WEIGHT weight_limit | ( | player_type * | creature_ptr | ) |
プレイヤーの所持重量制限を計算する / Computes current weight limit.
void wreck_the_pattern | ( | player_type * | creature_ptr | ) |
種族アンバライトが出血時パターンの上に乗った際のペナルティ処理
concptr your_alignment | ( | player_type * | creature_ptr | ) |
const byte adj_chr_chm[] |
魅力による魅了能力修正テーブル / Stat Table (CHR) – charm
const byte adj_chr_gold[] |
魅力による店での取引修正テーブル Stat Table (CHR) – payment percentages
const byte adj_con_fix[] |
耐久による基本HP自然治癒値テーブル / Stat Table (CON) – base regeneration rate
const byte adj_con_mhp[] |
耐久による基本HP自然治癒値テーブル / Stat Table (CON) – extra 1/4-hitpoints per level (plus 128)
const byte adj_dex_dis[] |
器用さによるトラップ解除修正テーブル Stat Table (DEX) – disarming
const byte adj_dex_safe[] |
器用さによる盗難防止&体当たり成功判定修正テーブル Stat Table (DEX) – chance of avoiding "theft" and "falling"
const byte adj_dex_ta[] |
器用さによるAC修正テーブル Stat Table (DEX) – bonus to ac (plus 128)
const byte adj_dex_th[] |
器用度による命中修正テーブル Stat Table (DEX) – bonus to hit (plus 128)
const byte adj_int_dev[] |
知力による魔道具使用修正テーブル Stat Table (INT) – Magic devices
const byte adj_int_dis[] |
知力によるトラップ解除修正テーブル Stat Table (INT) – disarming
const byte adj_mag_fail[] |
知力/賢さによる最低魔法失敗率テーブル Stat Table (INT/WIS) – Minimum failure rate (percentage)
const byte adj_mag_mana[] |
知力/賢さによるMP修正テーブル Stat Table (INT/WIS) – extra 1/4-mana-points per level
const byte adj_mag_stat[] |
知力/賢さによる魔法失敗率修正テーブル Stat Table (INT/WIS) – Various things
const byte adj_mag_study[] |
知力/賢さによるレベル毎の習得可能魔法数テーブル Stat Table (INT/WIS) – Number of half-spells per level
const byte adj_str_dig[] |
腕力による採掘能力修正値テーブル Stat Table (STR) – digging value
const byte adj_str_hold[] |
腕力による武器重量限界値テーブル Stat Table (STR) – weapon weight limit in pounds
const byte adj_str_td[] |
腕力によるダメージ修正テーブル Stat Table (STR) – bonus to dam (plus 128)
const byte adj_str_th[] |
腕力による命中修正テーブル Stat Table (STR) – bonus to hit (plus 128)
const byte adj_str_wgt[] |
腕力による基本所持重量値テーブル Stat Table (STR) – weight limit in deca-pounds
const byte adj_wis_sav[] |
賢さによる魔法防御修正テーブル Stat Table (WIS) – Saving throw
|
static |
ELDRITCH HORROR効果時の幻覚時間延長を示す錯乱表現
|
static |
ELDRITCH HORROR効果時のモンスターの形容メッセージ(幻覚状態時)
|
static |
ELDRITCH HORROR効果時のモンスターの形容メッセージ(通常時)
player_type p_body |
player_type* p_ptr = &p_body |
const s32b player_exp[PY_MAX_LEVEL] |
基本必要経験値テーブル / Base experience levels, may be adjusted up for race and/or class
const s32b player_exp_a[PY_MAX_LEVEL] |
基本必要強化値テーブル(アンドロイド専用)
const concptr stat_names[6] |
能力値テーブル / Abbreviations of healthy stats
const concptr stat_names_reduced[6] |
能力値テーブル(能力低下時) / Abbreviations of damaged stats