Hengband  2.2.1
関数
mspells2.c ファイル

モンスター魔法の実装(対モンスター処理) / Monster spells (attack monster) [詳解]

#include "angband.h"
#include "util.h"
#include "cmd-pet.h"
#include "floor.h"
#include "grid.h"
#include "quest.h"
#include "realm-hex.h"
#include "player-move.h"
#include "player-class.h"
#include "monster.h"
#include "monster-status.h"
#include "monster-spell.h"
#include "spells.h"
#include "dungeon.h"
#include "world.h"
#include "view-mainwindow.h"
mspells2.c の依存先関係図:

関数

static bool direct_beam (POSITION y1, POSITION x1, POSITION y2, POSITION x2, monster_type *m_ptr)
 モンスターが敵対モンスターにビームを当てること可能かを判定する / Determine if a beam spell will hit the target. [詳解]
 
static bool breath_direct (POSITION y1, POSITION x1, POSITION y2, POSITION x2, POSITION rad, EFFECT_ID typ, bool is_friend)
 モンスターが敵対モンスターに直接ブレスを当てることが可能かを判定する / Determine if a breath will hit the target. [詳解]
 
void get_project_point (POSITION sy, POSITION sx, POSITION *ty, POSITION *tx, BIT_FLAGS flg)
 モンスターが特殊能力の目標地点を決める処理 / Get the actual center point of ball spells (rad > 1) (originally from TOband) [詳解]
 
static bool dispel_check_monster (MONSTER_IDX m_idx, MONSTER_IDX t_idx)
 モンスターが敵モンスターに魔力消去を使うかどうかを返す / Check should monster cast dispel spell at other monster. [詳解]
 
bool monst_spell_monst (MONSTER_IDX m_idx)
 モンスターが敵モンスターに特殊能力を使う処理のメインルーチン / Monster tries to 'cast a spell' (or breath, etc) at another monster. [詳解]
 

詳解

モンスター魔法の実装(対モンスター処理) / Monster spells (attack monster)

日付
2014/01/17
著者
Copyright (c) 1997 Ben Harrison, James E. Wilson, Robert A. Koeneke
This software may be copied and distributed for educational, research,
and not for profit purposes provided that this copyright and statement
are included in all such copies. Other copyrights may also apply.
2014 Deskull rearranged comment for Doxygen.

関数詳解

◆ breath_direct()

static bool breath_direct ( POSITION  y1,
POSITION  x1,
POSITION  y2,
POSITION  x2,
POSITION  rad,
EFFECT_ID  typ,
bool  is_friend 
)
static

モンスターが敵対モンスターに直接ブレスを当てることが可能かを判定する / Determine if a breath will hit the target.

引数
y1始点のY座標
x1始点のX座標
y2目標のY座標
x2目標のX座標
rad半径
typ効果属性ID
is_friendTRUEならば、プレイヤーを巻き込む時にブレスの判定をFALSEにする。
戻り値
ブレスを直接当てられるならばTRUEを返す
呼び出し関係図:
被呼び出し関係図:

◆ direct_beam()

static bool direct_beam ( POSITION  y1,
POSITION  x1,
POSITION  y2,
POSITION  x2,
monster_type m_ptr 
)
static

モンスターが敵対モンスターにビームを当てること可能かを判定する / Determine if a beam spell will hit the target.

引数
y1始点のY座標
x1始点のX座標
y2目標のY座標
x2目標のX座標
m_ptr使用するモンスターの構造体参照ポインタ
戻り値
ビームが到達可能ならばTRUEを返す
呼び出し関係図:
被呼び出し関係図:

◆ dispel_check_monster()

static bool dispel_check_monster ( MONSTER_IDX  m_idx,
MONSTER_IDX  t_idx 
)
static

モンスターが敵モンスターに魔力消去を使うかどうかを返す / Check should monster cast dispel spell at other monster.

引数
m_idx術者のモンスターID
t_idx目標のモンスターID
戻り値
魔力消去を使うべきならばTRUEを変えす。
呼び出し関係図:
被呼び出し関係図:

◆ get_project_point()

void get_project_point ( POSITION  sy,
POSITION  sx,
POSITION ty,
POSITION tx,
BIT_FLAGS  flg 
)

モンスターが特殊能力の目標地点を決める処理 / Get the actual center point of ball spells (rad > 1) (originally from TOband)

引数
sy始点のY座標
sx始点のX座標
ty目標Y座標を返す参照ポインタ
tx目標X座標を返す参照ポインタ
flg判定のフラグ配列
戻り値
なし
呼び出し関係図:

◆ monst_spell_monst()

bool monst_spell_monst ( MONSTER_IDX  m_idx)

モンスターが敵モンスターに特殊能力を使う処理のメインルーチン / Monster tries to 'cast a spell' (or breath, etc) at another monster.

引数
m_idx術者のモンスターID
戻り値
実際に特殊能力を使った場合TRUEを返す

The player is only disturbed if able to be affected by the spell.

呼び出し関係図: