OSDN Git Service

[Refactor] #935 Removed inclusion for flag-group.h from player-status.h
[hengbandforosx/hengbandosx.git] / src / player / player-status.h
1 #pragma once
2
3 /*
4  * @file player-status.h
5  * @brief プレーヤーのステータスに関する状態取得処理ヘッダ
6  */
7
8 #include "system/angband.h"
9
10 // @todo 地雷、FlagGroupと強い関係がある
11 #include "player/player-classes-types.h"
12 #include "player/player-personalities-types.h"
13 #include "player/player-race-types.h"
14
15 typedef struct object_type object_type;
16 typedef struct player_type player_type;
17 concptr your_alignment(player_type *creature_ptr, bool with_value = false);
18 int weapon_exp_level(int weapon_exp);
19 int riding_exp_level(int riding_exp);
20 int spell_exp_level(int spell_exp);
21
22 int calc_weapon_weight_limit(player_type *creature_ptr);
23 WEIGHT calc_inventory_weight(player_type *creature_ptr);
24
25 s16b calc_num_fire(player_type *creature_ptr, object_type *o_ptr);
26 WEIGHT calc_weight_limit(player_type *creature_ptr);
27 bool has_melee_weapon(player_type *creature_ptr, int i);
28
29 bool heavy_armor(player_type *creature_ptr);
30 void update_creature(player_type *creature_ptr);
31 BIT_FLAGS16 empty_hands(player_type *creature_ptr, bool riding_control);
32 bool player_has_no_spellbooks(player_type *creature_ptr);
33
34 void take_turn(player_type *creature_ptr, PERCENTAGE need_cost);
35 void free_turn(player_type *creature_ptr);
36
37 bool player_place(player_type *creature_ptr, POSITION y, POSITION x);
38
39 void check_experience(player_type *creature_ptr);
40 void wreck_the_pattern(player_type *creature_ptr);
41 void cnv_stat(int val, char *out_val);
42 s16b modify_stat_value(int value, int amount);
43 long calc_score(player_type *creature_ptr);
44
45 bool is_blessed(player_type *creature_ptr);
46 bool is_time_limit_esp(player_type *creature_ptr);
47 bool is_time_limit_stealth(player_type *creature_ptr);
48 bool can_two_hands_wielding(player_type *creature_ptr);
49 bool is_fast(player_type *creature_ptr);
50 bool is_invuln(player_type *creature_ptr);
51 bool is_hero(player_type *creature_ptr);
52 bool is_shero(player_type *creature_ptr);
53 bool is_echizen(player_type *creature_ptr);
54 bool is_in_dungeon(player_type *creature_ptr);
55
56 void stop_singing(player_type *creature_ptr);
57 void stop_mouth(player_type *caster_ptr);
58 PERCENTAGE calculate_upkeep(player_type *creature_ptr);
59 bool music_singing(player_type *caster_ptr, int music_songs);
60
61 // @todo 後で普通の関数に直す
62 #define SINGING_SONG_EFFECT(P_PTR) ((P_PTR)->magic_num1[0])
63 #define INTERUPTING_SONG_EFFECT(P_PTR) ((P_PTR)->magic_num1[1])
64 #define SINGING_COUNT(P_PTR) ((P_PTR)->magic_num1[2])
65 #define SINGING_SONG_ID(P_PTR) ((P_PTR)->magic_num2[0])
66 #define music_singing_any(CREATURE_PTR) (((CREATURE_PTR)->pclass == CLASS_BARD) && (CREATURE_PTR)->magic_num1[0])