<commit_before>
/* <NAME>
Aug 15 2015 */

#ifndef NPC_ENEMY_BODYGUARD_H
#define NPC_ENEMY_BODYGUARD_H

#include "npc_enemy.h"

class Hostile_NPC_Bodyguard : public Hostile_NPC
{
public:
	Hostile_NPC_Bodyguard(const std::string & name, const std::string & set_protect_target_id) : Hostile_NPC(name),
		protect_target_id(set_protect_target_id), hunt_target_last_known_location(-1, -1), guard_radius(5), hunt_radius(15) {}

	Update_Messages update(World & world, std::map<std::string, std::shared_ptr<Character>> & actors);

	void set_protect_target(const std::string & set_protect_target_id);

private:
	enum class Stored_Path_Type { to_hunt_target, to_protect_target };

	// NPC bodyguards will stay within guard_radius rooms of the NPC they are protecting
	int guard_radius; // measured in diagonal/Chebyshev distance, not Euclidian distance
	// stores the max distance from the protect_target that the NPC will pursue the hunt_target
	int hunt_radius; // same units as above
	Stored_Path_Type stored_path_type;
	Coordinate hunt_target_last_known_location;
	std::string hunt_target_id = "", protect_target_id = "";
<commit_msg>change NPC bodyguard hunt radius to C::VIEW_DISTANCE<commit_after>
/* <NAME>
Aug 15 2015 */

#ifndef NPC_ENEMY_BODYGUARD_H
#define NPC_ENEMY_BODYGUARD_H

#include "npc_enemy.h"

class Hostile_NPC_Bodyguard : public Hostile_NPC
{
public:
	Hostile_NPC_Bodyguard(const std::string & name, const std::string & set_protect_target_id) : Hostile_NPC(name),
		protect_target_id(set_protect_target_id), hunt_target_last_known_location(-1, -1), guard_radius(C::VIEW_DISTANCE), hunt_radius(15) {}

	Update_Messages update(World & world, std::map<std::string, std::shared_ptr<Character>> & actors);

	void set_protect_target(const std::string & set_protect_target_id);

private:
	enum class Stored_Path_Type { to_hunt_target, to_protect_target };

	// NPC bodyguards will stay within guard_radius rooms of the NPC they are protecting
	int guard_radius; // measured in diagonal/Chebyshev distance, not Euclidian distance
	// stores the max distance from the protect_target that the NPC will pursue the hunt_target
	int hunt_radius; // same units as above
	Stored_Path_Type stored_path_type;
	Coordinate hunt_target_last_known_location;
	std::string hunt_target_id = "", protect_target_id = "";

{'fraction_non_alphanumeric': 0.08752166377816291, 'fraction_numerical': 0.009098786828422877, 'mean_word_length': 6.62046204620462, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3610558', 'n_tokens_mistral': 819, 'n_tokens_neox': 759, 'n_words': 192}