Hengband
2.2.1
|
#include "angband.h"
#include "util.h"
#include "cmd-dump.h"
#include "trap.h"
#include "player-damage.h"
#include "player-move.h"
#include "player-effects.h"
#include "player-class.h"
#include "player-personality.h"
#include "spells-summon.h"
#include "quest.h"
#include "artifact.h"
#include "feature.h"
#include "player-status.h"
#include "grid.h"
#include "spells.h"
#include "floor.h"
#include "floor-save.h"
#include "init.h"
#include "files.h"
#include "dungeon.h"
#include "world.h"
#include "realm-song.h"
関数 | |
void | init_normal_traps (void) |
タグに従って、基本トラップテーブルを初期化する / Initialize arrays for normal traps [詳解] | |
FEAT_IDX | choose_random_trap (void) |
基本トラップをランダムに選択する / Get random trap [詳解] | |
void | disclose_grid (POSITION y, POSITION x) |
マスに存在する隠しトラップを公開する / Disclose an invisible trap [詳解] | |
void | place_trap (floor_type *floor_ptr, POSITION y, POSITION x) |
マスをトラップを配置する / The location must be a legal, naked, floor grid. [詳解] | |
static int | check_hit (int power) |
プレイヤーへのトラップ命中判定 / Determine if a trap affects the player. [詳解] | |
static void | hit_trap_pit (int trap_feat_type) |
落とし穴系トラップの判定とプレイヤーの被害処理 [詳解] | |
static bool | hit_trap_dart (void) |
ダーツ系トラップ(通常ダメージ)の判定とプレイヤーの被害処理 [詳解] | |
static void | hit_trap_lose_stat (int stat) |
ダーツ系トラップ(通常ダメージ+能力値減少)の判定とプレイヤーの被害処理 [詳解] | |
static void | hit_trap_slow (void) |
ダーツ系トラップ(通常ダメージ+減速)の判定とプレイヤーの被害処理 [詳解] | |
static void | hit_trap_set_abnormal_status (concptr trap_message, bool resist, bool(*set_status)(IDX), IDX turn_aux) |
ダーツ系トラップ(通常ダメージ+状態異常)の判定とプレイヤーの被害処理 [詳解] | |
static void | hit_trap_set_abnormal_status_p (concptr trap_message, bool resist, bool(*set_status)(player_type *, IDX), IDX turn_aux) |
void | hit_trap (player_type *trapped_ptr, bool break_trap) |
プレイヤーへのトラップ作動処理メインルーチン / Handle player hitting a real trap [詳解] | |
変数 | |
static s16b | normal_traps [MAX_NORMAL_TRAPS] |
const int | chest_traps [64] |
箱のトラップテーブル [詳解] | |
|
static |
プレイヤーへのトラップ命中判定 / Determine if a trap affects the player.
power | 基本回避難度 |
Always miss 5% of the time, Always hit 5% of the time. Otherwise, match trap power against player armor.
FEAT_IDX choose_random_trap | ( | void | ) |
基本トラップをランダムに選択する / Get random trap
This routine should be redone to reflect trap "level".
That is, it does not make sense to have spiked pits at 50 feet.
Actually, it is not this routine, but the "trap instantiation"
code, which should also check for "trap doors" on quest levels.
マスに存在する隠しトラップを公開する / Disclose an invisible trap
y | 秘匿したいマスのY座標 |
x | 秘匿したいマスのX座標 |
void hit_trap | ( | player_type * | trapped_ptr, |
bool | break_trap | ||
) |
プレイヤーへのトラップ作動処理メインルーチン / Handle player hitting a real trap
break_trap | 作動後のトラップ破壊が確定しているならばTRUE |
|
static |
ダーツ系トラップ(通常ダメージ)の判定とプレイヤーの被害処理
|
static |
ダーツ系トラップ(通常ダメージ+能力値減少)の判定とプレイヤーの被害処理
stat | 低下する能力値ID |
|
static |
落とし穴系トラップの判定とプレイヤーの被害処理
trap_feat_type | トラップの種別ID |
|
static |
ダーツ系トラップ(通常ダメージ+状態異常)の判定とプレイヤーの被害処理
trap_message | メッセージの補完文字列 |
resist | 状態異常に抵抗する判定が出たならTRUE |
set_status | 状態異常を指定する関数ポインタ |
turn_aux | 状態異常の追加ターン量 |
|
static |
|
static |
ダーツ系トラップ(通常ダメージ+減速)の判定とプレイヤーの被害処理
void init_normal_traps | ( | void | ) |
タグに従って、基本トラップテーブルを初期化する / Initialize arrays for normal traps
void place_trap | ( | floor_type * | floor_ptr, |
POSITION | y, | ||
POSITION | x | ||
) |
マスをトラップを配置する / The location must be a legal, naked, floor grid.
y | 配置したいマスのY座標 |
x | 配置したいマスのX座標 |
const int chest_traps[64] |
箱のトラップテーブル
Each chest has a certain set of traps, determined by pval Each chest has a "pval" from 1 to the chest level (max 55) If the "pval" is negative then the trap has been disarmed The "pval" of a chest determines the quality of its treasure Note that disarming a trap on a chest also removes the lock.
|
static |