|
Pol
Rev 533
|
#include <npc.h>
Inheritance diagram for NPC:
Collaboration diagram for NPC:Public Member Functions | |
| NPC (u32 objtype, const ConfigElem &elem) | |
| NpcTemplate::ALIGNMENT | alignment () const |
| bool | anchor_allows_move (UFACING dir) const |
| virtual void | apply_raw_damage_hundredths (unsigned int damage, Character *source, bool userepsys=true, bool send_damage_packet=false) |
| virtual unsigned short | ar () const |
| virtual double | armor_absorb_damage (double damage) |
| bool | can_accept_event (EVENTID eventid) |
| virtual bool | can_be_renamed_by (const Character *chr) const |
| const char * | classname () const |
| bool | could_move (UFACING dir) const |
| virtual BObjectImp * | custom_script_method (const char *methodname, Executor &ex) |
| virtual void | destroy () |
| virtual void | get_hitscript_params (double damage, UArmor **parmor, unsigned short *rawdamage) |
| virtual BObjectImp * | get_script_member (const char *membername) const |
| virtual BObjectImp * | get_script_member_id (const int id) const |
| virtual void | inform_criminal (Character *thecriminal) |
| virtual void | inform_disengaged (Character *disengaged) |
| virtual void | inform_engaged (Character *engaged) |
| virtual void | inform_enteredarea (Character *whoentered) |
| virtual void | inform_imoved (Character *chr) |
| virtual void | inform_leftarea (Character *wholeft) |
| virtual void | inform_moved (Character *moved) |
| virtual UWeapon * | intrinsic_weapon () |
| void | loadDamages (int damageType, ConfigElem &elem) |
| void | loadResistances (int resistanceType, ConfigElem &elem) |
| Character * | master () const |
| bool | npc_path_blocked (UFACING dir) const |
| virtual void | on_death (Item *corpse) |
| virtual void | on_ghost_pc_spoke (Character *src_chr, const char *speech, u8 texttype) |
| virtual void | on_ghost_pc_spoke (Character *src_chr, const char *speech, u8 texttype, const u16 *wspeech, const char lang[4], ObjArray *speechtokens=NULL) |
| virtual void | on_give_item () |
| virtual void | on_pc_spoke (Character *src_chr, const char *speech, u8 texttype) |
| virtual void | on_pc_spoke (Character *src_chr, const char *speech, u8 texttype, const u16 *wspeech, const char lang[4], ObjArray *speechtokens=NULL) |
| virtual void | printDebugProperties (std::ostream &os) const |
| virtual void | printOn (std::ostream &os) const |
| virtual void | printProperties (std::ostream &os) const |
| virtual void | printSelfOn (std::ostream &os) const |
| void | readNewNpcAttributes (ConfigElem &elem) |
| void | readNpcProperties (ConfigElem &elem) |
| virtual void | readProperties (ConfigElem &elem) |
| void | readPropertiesForNewNPC (ConfigElem &elem) |
| virtual void | refresh_ar () |
| void | restart_script () |
| virtual bool | script_isa (unsigned isatype) const |
| virtual BObjectImp * | script_method (const char *methodname, Executor &ex) |
| virtual BObjectImp * | script_method_id (const int id, Executor &ex) |
| BObjectImp * | send_event (BObjectImp *event) |
| virtual BObjectImp * | set_script_member (const char *membername, int value) |
| id test | |
| virtual BObjectImp * | set_script_member (const char *membername, const std::string &) |
| id test | |
| virtual BObjectImp * | set_script_member_id (const int id, int value) |
| virtual BObjectImp * | set_script_member_id (const int id, const std::string &) |
| void | start_script () |
Public Attributes | |
| unsigned short | damaged_sound |
| unsigned short | run_speed |
| bool | use_adjustments |
| unsigned short | dstart |
| bool | enabled |
| unsigned short | psub |
| unsigned short | x |
| unsigned short | y |
Protected Member Functions | |
| void | stop_scripts () |
Protected Attributes | |
| UOExecutor * | ex |
| UOExecutor * | give_item_ex |
| std::string | template_name |
Private Types | |
| typedef Character | base |
Private Member Functions | |
| NPC (const NPC &npc) | |
| virtual | ~NPC () |
| virtual unsigned char | hilite_color_idx (const Character *seen_by) const |
| virtual unsigned short | name_color (const Character *seen_by) const |
| NPC & | operator= (const NPC &npc) |
| virtual void | repsys_on_attack (Character *defender) |
| virtual void | repsys_on_damage (Character *defender) |
| virtual void | repsys_on_help (Character *recipient) |
| void | reset_element_damage (unsigned damage) |
| void | reset_element_resist (unsigned resist) |
Private Attributes | |
| struct { | |
| unsigned short dstart | |
| bool enabled | |
| unsigned short psub | |
| unsigned short x | |
| unsigned short y | |
| } | anchor |
| ElementDamages | element_damage_ |
| Resistances | element_resist_ |
| CharacterRef | master_ |
| unsigned short | npc_ar_ |
| std::string | script |
| unsigned short | speech_color_ |
| unsigned short | speech_font_ |
| const NpcTemplate & | template_ |
Friends | |
| class | NPCExecutorModule |
| class | ref_ptr< NPC > |
| class | RepSystem |
| NPC::NPC | ( | u32 | objtype, |
| const ConfigElem & | elem | ||
| ) | [explicit] |
Definition at line 97 of file npc.cpp.
References anchor, Character::connected, Character::logged_in, and npc_count.
| NPC::~NPC | ( | ) | [private, virtual] |
Definition at line 115 of file npc.cpp.
References npc_count, and stop_scripts().
Here is the call graph for this function:| NpcTemplate::ALIGNMENT NPC::alignment | ( | ) | const [inline] |
Definition at line 165 of file npc.h.
Referenced by Character::repsys_on_attack(), Character::repsys_on_damage(), and Character::repsys_on_help().
Here is the caller graph for this function:| bool NPC::anchor_allows_move | ( | UFACING | dir | ) | const |
Definition at line 162 of file npc.cpp.
References anchor, Character::dir, move_delta, pol_distance(), random_int(), Character::warmode, x, MoveDelta::xmove, y, and MoveDelta::ymove.
Referenced by could_move(), and NPCExecutorModule::move_self().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::apply_raw_damage_hundredths | ( | unsigned int | damage, |
| Character * | source, | ||
| bool | userepsys = true, |
||
| bool | send_damage_packet = false |
||
| ) | [virtual] |
Reimplemented from Character.
Definition at line 927 of file npc.cpp.
References Character::apply_raw_damage_hundredths(), UOExecutor::eventmask, EVID_DAMAGED, ex, UOExecutor::os_module, and OSExecutorModule::signal_event().
Here is the call graph for this function:| unsigned short NPC::ar | ( | ) | const [inline, virtual] |
Reimplemented from Character.
Definition at line 183 of file npc.h.
References Character::ar_, and npc_ar_.
| double NPC::armor_absorb_damage | ( | double | damage | ) | [virtual] |
Reimplemented from Character.
Definition at line 948 of file npc.cpp.
References Character::ar_mod(), Character::armor_absorb_damage(), Watch::combat, npc_ar_, random_int(), and watch.
Here is the call graph for this function:| bool NPC::can_accept_event | ( | EVENTID | eventid | ) |
Definition at line 901 of file npc.cpp.
References UOExecutor::eventmask, and ex.
Referenced by PrivUpdater::disable_see_ghosts(), PrivUpdater::disable_see_hidden(), doubleclick(), drop_item_on_mobile(), PrivUpdater::enable_see_ghosts(), and PrivUpdater::enable_see_hidden().
Here is the caller graph for this function:| bool NPC::can_be_renamed_by | ( | const Character * | chr | ) | const [virtual] |
Reimplemented from Character.
Definition at line 655 of file npc.cpp.
References ref_ptr< T >::get(), and master_.
Here is the call graph for this function:| const char * NPC::classname | ( | ) | const [virtual] |
| bool NPC::could_move | ( | UFACING | dir | ) | const |
Definition at line 186 of file npc.cpp.
References anchor_allows_move(), Character::dir, Character::gradual_boost, move_delta, npc_path_blocked(), UObject::realm, Realm::walkheight(), x, MoveDelta::xmove, y, MoveDelta::ymove, and UObject::z.
Referenced by NPCExecutorModule::_internal_move(), and NPCExecutorModule::CanMove().
Here is the call graph for this function:
Here is the caller graph for this function:| BObjectImp * NPC::custom_script_method | ( | const char * | methodname, |
| Executor & | ex | ||
| ) | [virtual] |
Reimplemented from Character.
Definition at line 2509 of file uoscrobj.cpp.
References ExportScript::call(), ExportScript::FindExportedFunction(), Executor::fparams, Character::make_ref(), NpcTemplate::method_script, Executor::numParams(), and template_.
Here is the call graph for this function:| void NPC::destroy | ( | ) | [virtual] |
Reimplemented from Character.
Definition at line 131 of file npc.cpp.
References UMulti::as_house(), Character::destroy(), UContainer::destroy_contents(), Character::registered_house, system_find_multi(), UHouse::unregister_object(), and Character::wornitems.
Referenced by on_death().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::get_hitscript_params | ( | double | damage, |
| UArmor ** | parmor, | ||
| unsigned short * | rawdamage | ||
| ) | [virtual] |
Reimplemented from Character.
Definition at line 972 of file npc.cpp.
References Character::ar_mod(), calc_thru_damage(), Character::get_hitscript_params(), and npc_ar_.
Here is the call graph for this function:| BObjectImp * NPC::get_script_member | ( | const char * | membername | ) | const [virtual] |
Reimplemented from Character.
Definition at line 2413 of file uoscrobj.cpp.
References get_script_member_id(), getKnownObjMember(), and ObjMember::id.
Here is the call graph for this function:| BObjectImp * NPC::get_script_member_id | ( | const int | id | ) | const [virtual] |
Reimplemented from Character.
Definition at line 2369 of file uoscrobj.cpp.
References NpcTemplate::alignment, UOExecutor::eventmask, ex, ref_ptr< T >::get(), Character::get_script_member_id(), master(), master_, MBR_ALIGNMENT, MBR_EVENTMASK, MBR_MASTER, MBR_NPCTEMPLATE, MBR_PROCESS, MBR_RUN_SPEED, MBR_SAVEONEXIT, MBR_SCRIPT, MBR_SPEECH_COLOR, MBR_SPEECH_FONT, MBR_USE_ADJUSTMENTS, UObject::orphan(), run_speed, UObject::saveonexit(), script, speech_color_, speech_font_, template_, template_name, and use_adjustments.
Referenced by get_script_member().
Here is the call graph for this function:
Here is the caller graph for this function:| unsigned char NPC::hilite_color_idx | ( | const Character * | seen_by | ) | const [private, virtual] |
[16] NPC Highlighting If the NPC has a master, Highlight color is the same as the Master's. Else the NPC is invul Hilite them invul is ssopt.cfg option says to. Else Highlight Good NPCs INNOCENT (Blue) Highlight Neutral NPCs ATTACKABLE (Grey) Highlight Evil NPCs MURDERER (Red)
Reimplemented from Character.
Definition at line 993 of file repsys.cpp.
References NpcTemplate::alignment, ExportedFunction::call_long(), CHAR_HILITE_ATTACKABLE, CHAR_HILITE_INNOCENT, CHAR_HILITE_INVUL, CHAR_HILITE_MURDERER, NpcTemplate::EVIL, NpcTemplate::GOOD, RepSys_Cfg::HighLightColor, RepSys_Cfg::Hooks, Character::invul(), ServSpecOpt::invul_tag, Character::is_criminal(), Character::is_murderer(), Character::make_ref(), master(), NpcTemplate::NEUTRAL, repsys_cfg, ssopt, and template_.
Here is the call graph for this function:| void NPC::inform_criminal | ( | Character * | thecriminal | ) | [virtual] |
Reimplemented from Character.
Definition at line 780 of file npc.cpp.
References UOExecutor::area_size, ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_GONE_CRIMINAL, ex, inrangex(), Character::is_visible_to_me(), UOExecutor::os_module, OSExecutorModule::signal_event(), and ssopt.
Here is the call graph for this function:| void NPC::inform_disengaged | ( | Character * | disengaged | ) | [virtual] |
Reimplemented from Character.
Definition at line 767 of file npc.cpp.
References UOExecutor::eventmask, EVID_DISENGAGED, ex, UOExecutor::os_module, and OSExecutorModule::signal_event().
Here is the call graph for this function:| void NPC::inform_engaged | ( | Character * | engaged | ) | [virtual] |
Reimplemented from Character.
Definition at line 754 of file npc.cpp.
References UOExecutor::eventmask, EVID_ENGAGED, ex, UOExecutor::os_module, and OSExecutorModule::signal_event().
Here is the call graph for this function:| void NPC::inform_enteredarea | ( | Character * | whoentered | ) | [virtual] |
Reimplemented from Character.
Definition at line 807 of file npc.cpp.
References UOExecutor::area_size, ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_ENTEREDAREA, ex, Character::is_visible_to_me(), UOExecutor::os_module, pol_distance(), OSExecutorModule::signal_event(), and ssopt.
Here is the call graph for this function:| void NPC::inform_imoved | ( | Character * | chr | ) | [virtual] |
Reimplemented from Character.
Definition at line 874 of file npc.cpp.
References UOExecutor::area_size, ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_ENTEREDAREA, EVID_LEFTAREA, ex, Character::is_visible_to_me(), Character::lastx, Character::lasty, UOExecutor::os_module, passert, OSExecutorModule::signal_event(), ssopt, x, UObject::x, y, and UObject::y.
Here is the call graph for this function:| void NPC::inform_leftarea | ( | Character * | wholeft | ) | [virtual] |
Reimplemented from Character.
Definition at line 792 of file npc.cpp.
References UOExecutor::area_size, ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_LEFTAREA, ex, Character::is_visible_to_me(), UOExecutor::os_module, pol_distance(), OSExecutorModule::signal_event(), and ssopt.
Here is the call graph for this function:| void NPC::inform_moved | ( | Character * | moved | ) | [virtual] |
Reimplemented from Character.
Definition at line 822 of file npc.cpp.
References UOExecutor::area_size, ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_ENTEREDAREA, EVID_LEFTAREA, EVID_OPPONENT_MOVED, ex, Character::is_visible_to_me(), Character::lastx, Character::lasty, Character::opponent_, UOExecutor::os_module, passert, OSExecutorModule::signal_event(), ssopt, x, UObject::x, y, and UObject::y.
Here is the call graph for this function:| UWeapon * NPC::intrinsic_weapon | ( | ) | [virtual] |
Reimplemented from Character.
Definition at line 986 of file npc.cpp.
References NpcTemplate::intrinsic_weapon, template_, and wrestling_weapon.
| void NPC::loadDamages | ( | int | damageType, |
| ConfigElem & | elem | ||
| ) |
Definition at line 453 of file npc.cpp.
References ElementDamages::cold, ElementDamages_Mods::cold, UObject::element_damage, element_damage_, UObject::element_damage_mod, ElementDamages::energy, ElementDamages_Mods::energy, ElementDamages::fire, ElementDamages_Mods::fire, Dice::load(), ElementDamages::physical, ElementDamages_Mods::physical, ElementDamages::poison, ElementDamages_Mods::poison, ConfigElem::remove_prop(), and Dice::roll().
Referenced by readNpcProperties().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::loadResistances | ( | int | resistanceType, |
| ConfigElem & | elem | ||
| ) |
Definition at line 379 of file npc.cpp.
References Resistances::cold, Resistances_Mods::cold, UObject::element_resist, element_resist_, UObject::element_resist_mod, Resistances::energy, Resistances_Mods::energy, Resistances::fire, Resistances_Mods::fire, Dice::load(), npc_ar_, Resistances::physical, Resistances_Mods::physical, Resistances::poison, Resistances_Mods::poison, ConfigElem::remove_prop(), and Dice::roll().
Referenced by readNpcProperties().
Here is the call graph for this function:
Here is the caller graph for this function:| Character * NPC::master | ( | ) | const [inline] |
Definition at line 160 of file npc.h.
References ref_ptr< T >::get(), and master_.
Referenced by get_script_member_id(), hilite_color_idx(), name_color(), repsys_on_attack(), Character::repsys_on_attack(), repsys_on_damage(), Character::repsys_on_damage(), repsys_on_help(), and Character::repsys_on_help().
Here is the call graph for this function:
Here is the caller graph for this function:| unsigned short NPC::name_color | ( | const Character * | seen_by | ) | const [private, virtual] |
Reimplemented from Character.
Definition at line 1032 of file repsys.cpp.
References NpcTemplate::alignment, RepSys_Cfg::Attackable, ExportedFunction::call_long(), RepSys_Cfg::Criminal, NpcTemplate::EVIL, NpcTemplate::GOOD, RepSys_Cfg::Hooks, RepSys_Cfg::Innocent, Character::invul(), ServSpecOpt::invul_tag, RepSys_Cfg::Invulnerable, Character::is_criminal(), Character::is_murderer(), Character::make_ref(), master(), RepSys_Cfg::Murderer, RepSys_Cfg::NameColor, RepSys_Cfg::NameColoring, NpcTemplate::NEUTRAL, repsys_cfg, ssopt, and template_.
Here is the call graph for this function:| bool NPC::npc_path_blocked | ( | UFACING | dir | ) | const |
Definition at line 217 of file npc.cpp.
References Character::cached_settings, Zone::characters, Character::dead(), Character::dir, Character::is_visible_to_me(), move_delta, UObject::realm, x, UObject::x, MoveDelta::xmove, y, UObject::y, MoveDelta::ymove, UObject::z, Realm::zone, and zone_convert_clip().
Referenced by could_move().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::on_death | ( | Item * | corpse | ) | [virtual] |
Reimplemented from Character.
Definition at line 597 of file npc.cpp.
References ClrCharacterWorldPosition(), destroy(), ex, FileExists(), OSExecutorModule::in_debugger_holdlist(), UOExecutor::os_module, OSExecutorModule::revive(), OSExecutorModule::revive_debugged(), send_remove_character_to_nearby(), Executor::seterror(), UObject::setprop(), start_script(), and template_name.
Here is the call graph for this function:| void NPC::on_ghost_pc_spoke | ( | Character * | src_chr, |
| const char * | speech, | ||
| u8 | texttype | ||
| ) | [virtual] |
Definition at line 687 of file npc.cpp.
References Character::deafened(), ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_GHOST_SPEECH, ex, inrangex(), Character::is_visible_to_me(), UOExecutor::os_module, OSExecutorModule::signal_event(), UOExecutor::speech_size, ssopt, and TextTypeToString().
Referenced by ghost_pc_spoke().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::on_ghost_pc_spoke | ( | Character * | src_chr, |
| const char * | speech, | ||
| u8 | texttype, | ||
| const u16 * | wspeech, | ||
| const char | lang[4], | ||
| ObjArray * | speechtokens = NULL |
||
| ) | [virtual] |
Definition at line 728 of file npc.cpp.
References Character::deafened(), ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_GHOST_SPEECH, EVID_TOKEN_GHOST_SPOKE, ex, inrangex(), Character::is_visible_to_me(), UOExecutor::os_module, ServSpecOpt::seperate_speechtoken, OSExecutorModule::signal_event(), UOExecutor::speech_size, ssopt, and TextTypeToString().
Here is the call graph for this function:| void NPC::on_give_item | ( | ) | [virtual] |
| void NPC::on_pc_spoke | ( | Character * | src_chr, |
| const char * | speech, | ||
| u8 | texttype | ||
| ) | [virtual] |
Definition at line 666 of file npc.cpp.
References Character::deafened(), ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_SPOKE, ex, inrangex(), Character::is_visible_to_me(), UOExecutor::os_module, OSExecutorModule::signal_event(), UOExecutor::speech_size, ssopt, and TextTypeToString().
Referenced by npc_spoke(), and pc_spoke().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::on_pc_spoke | ( | Character * | src_chr, |
| const char * | speech, | ||
| u8 | texttype, | ||
| const u16 * | wspeech, | ||
| const char | lang[4], | ||
| ObjArray * | speechtokens = NULL |
||
| ) | [virtual] |
Definition at line 702 of file npc.cpp.
References Character::deafened(), ServSpecOpt::event_visibility_core_checks, UOExecutor::eventmask, EVID_SPOKE, EVID_TOKEN_SPOKE, ex, inrangex(), Character::is_visible_to_me(), UOExecutor::os_module, ServSpecOpt::seperate_speechtoken, OSExecutorModule::signal_event(), UOExecutor::speech_size, ssopt, and TextTypeToString().
Here is the call graph for this function:| void NPC::printDebugProperties | ( | std::ostream & | os | ) | const [virtual] |
| void NPC::printOn | ( | std::ostream & | os | ) | const [virtual] |
Reimplemented from Character.
Definition at line 243 of file npc.cpp.
References classname(), pf_endl, printProperties(), and template_name.
Referenced by printSelfOn().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::printProperties | ( | std::ostream & | os | ) | const [virtual] |
Reimplemented from Character.
Definition at line 257 of file npc.cpp.
References Resistances::cold, ElementDamages::cold, DEFAULT_TEXT_COLOR, DEFAULT_TEXT_FONT, Character::dexterity(), element_damage_, element_resist_, Resistances::energy, ElementDamages::energy, Resistances::fire, ElementDamages::fire, ref_ptr< T >::get(), master_, npc_ar_, pf_endl, Resistances::physical, ElementDamages::physical, Resistances::poison, ElementDamages::poison, Character::printProperties(), Character::registered_house, run_speed, script, speech_color_, speech_font_, and use_adjustments.
Referenced by printOn().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::printSelfOn | ( | std::ostream & | os | ) | const [virtual] |
| void NPC::readNewNpcAttributes | ( | ConfigElem & | elem | ) |
Definition at line 538 of file npc.cpp.
References Character::attribute(), ATTRIBUTE_MAX_BASE, AttributeValue::base(), FindAttribute(), Dice::load(), Attribute::next, ConfigElem::remove_prop(), Dice::roll(), and ConfigElem::throw_error().
Referenced by readPropertiesForNewNPC().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::readNpcProperties | ( | ConfigElem & | elem | ) |
Definition at line 321 of file npc.cpp.
References create_intrinsic_weapon_from_npctemplate(), damaged_sound, DEFAULT_TEXT_COLOR, DEFAULT_TEXT_FONT, Character::dexterity(), find_intrinsic_weapon(), UObject::getprop(), loadDamages(), loadResistances(), master_, NpcTemplate::pkg, Character::registered_house, ConfigElem::remove_bool(), ConfigElem::remove_prop(), ConfigElem::remove_string(), ConfigElem::remove_ulong(), ConfigElem::remove_ushort(), ConfigElemBase::rest(), run_speed, UObject::saveonexit_, script, CharacterRef::set(), speech_color_, speech_font_, start_script(), system_find_mobile(), template_, template_name, use_adjustments, and Character::weapon.
Referenced by readProperties(), and readPropertiesForNewNPC().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::readProperties | ( | ConfigElem & | elem | ) | [virtual] |
Reimplemented from Character.
Definition at line 520 of file npc.cpp.
References UObject::getprop(), readNpcProperties(), Character::readProperties(), ConfigElemBase::rest(), and template_name.
Here is the call graph for this function:| void NPC::readPropertiesForNewNPC | ( | ConfigElem & | elem | ) |
Definition at line 569 of file npc.cpp.
References Character::calc_vital_stuff(), Character::readCommonProperties(), readNewNpcAttributes(), readNpcProperties(), and Character::set_vitals_to_maximum().
Referenced by add_npc().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::refresh_ar | ( | ) | [virtual] |
Reimplemented from Character.
Definition at line 1002 of file npc.cpp.
References UArmor::ar(), Character::ar_, Character::ar_mod(), Character::armor_, armorzones, Character::attribute(), Attribute::attrid, Item::calc_element_damage(), Item::calc_element_resist(), UObject::CLASS_ARMOR, AttributeValue::effective(), ELEMENTAL_TYPE_MAX, WornItemsContainer::GetItemOnLayer(), UObject::isa(), LAYER_EQUIP__HIGHEST, LAYER_EQUIP__LOWEST, pAttrParry, Character::refresh_element(), reset_element_damage(), reset_element_resist(), Character::shield, UArmor::tmplzones(), Character::update_element(), and Character::wornitems.
Here is the call graph for this function:| void NPC::repsys_on_attack | ( | Character * | defender | ) | [private, virtual] |
[13.2] NPC (MA) Attacks Mobile (MB) If MA has a Master (Amy), Apply 'Player Attacks Mobile' rules[->13.1] for Amy vs MB Else Exit with no (RepSystem) effect.
Reimplemented from Character.
Definition at line 835 of file repsys.cpp.
References ExportedFunction::call(), RepSys_Cfg::Hooks, Character::make_ref(), master(), master_, RepSys_Cfg::OnAttack, and repsys_cfg.
Here is the call graph for this function:| void NPC::repsys_on_damage | ( | Character * | defender | ) | [private, virtual] |
[14.2] NPC (MA) Damages Mobile (MB) If MA has a Master (Amy), Apply 'Player Damages Mobile' rules[->14.1] for Amy vs MB Else Exit with no (RepSystem) effect.
Reimplemented from Character.
Definition at line 896 of file repsys.cpp.
References ExportedFunction::call(), RepSys_Cfg::Hooks, Character::make_ref(), master(), master_, RepSys_Cfg::OnDamage, and repsys_cfg.
Here is the call graph for this function:| void NPC::repsys_on_help | ( | Character * | helped | ) | [private, virtual] |
[15.2] NPC (MA) Helps Mobile (MB) If MA has a Master (Amy), Apply 'Player Helps Mobile' rules[->15.1] for Amy helps MB Else Exit with no (RepSystem) effect.
Reimplemented from Character.
Definition at line 956 of file repsys.cpp.
References ExportedFunction::call(), RepSys_Cfg::Hooks, Character::make_ref(), master(), master_, RepSys_Cfg::OnHelp, and repsys_cfg.
Here is the call graph for this function:| void NPC::reset_element_damage | ( | unsigned | damage | ) | [private] |
Definition at line 1107 of file npc.cpp.
References ElementDamages::cold, ElementDamages_Mods::cold, UObject::element_damage, element_damage_, UObject::element_damage_mod, ELEMENTAL_COLD, ELEMENTAL_ENERGY, ELEMENTAL_FIRE, ELEMENTAL_PHYSICAL, ELEMENTAL_POISON, ElementDamages::energy, ElementDamages_Mods::energy, ElementDamages::fire, ElementDamages_Mods::fire, ElementDamages::physical, ElementDamages_Mods::physical, ElementDamages::poison, and ElementDamages_Mods::poison.
Referenced by refresh_ar().
Here is the caller graph for this function:| void NPC::reset_element_resist | ( | unsigned | resist | ) | [private] |
Definition at line 1095 of file npc.cpp.
References Resistances::cold, Resistances_Mods::cold, UObject::element_resist, element_resist_, UObject::element_resist_mod, ELEMENTAL_COLD, ELEMENTAL_ENERGY, ELEMENTAL_FIRE, ELEMENTAL_PHYSICAL, ELEMENTAL_POISON, Resistances::energy, Resistances_Mods::energy, Resistances::fire, Resistances_Mods::fire, Resistances::physical, Resistances_Mods::physical, Resistances::poison, and Resistances_Mods::poison.
Referenced by refresh_ar().
Here is the caller graph for this function:| void NPC::restart_script | ( | ) |
Definition at line 580 of file npc.cpp.
References ex, OSExecutorModule::in_debugger_holdlist(), UOExecutor::os_module, OSExecutorModule::revive(), OSExecutorModule::revive_debugged(), script, Executor::seterror(), and start_script().
Referenced by UOExecutorModule::mf_RestartScript().
Here is the call graph for this function:
Here is the caller graph for this function:| bool NPC::script_isa | ( | unsigned | isatype | ) | const [virtual] |
Reimplemented from Character.
Definition at line 3670 of file uoscrobj.cpp.
References POLCLASS_NPC, and Character::script_isa().
Here is the call graph for this function:| BObjectImp * NPC::script_method | ( | const char * | methodname, |
| Executor & | ex | ||
| ) | [virtual] |
Reimplemented from Character.
Definition at line 2500 of file uoscrobj.cpp.
References getKnownObjMethod(), ObjMethod::id, and script_method_id().
Here is the call graph for this function:| BObjectImp * NPC::script_method_id | ( | const int | id, |
| Executor & | ex | ||
| ) | [virtual] |
Reimplemented from Character.
Definition at line 2469 of file uoscrobj.cpp.
References CharacterRef::clear(), getCharacterParam(), master_, MTH_SETMASTER, Executor::numParams(), Character::script_method_id(), CharacterRef::set(), and UObject::set_dirty().
Referenced by script_method().
Here is the call graph for this function:
Here is the caller graph for this function:| BObjectImp * NPC::send_event | ( | BObjectImp * | event | ) |
Definition at line 911 of file npc.cpp.
References ex, UOExecutor::os_module, and OSExecutorModule::signal_event().
Referenced by buyhandler(), PrivUpdater::disable_see_ghosts(), PrivUpdater::disable_see_hidden(), doubleclick(), drop_item_on_mobile(), PrivUpdater::enable_see_ghosts(), PrivUpdater::enable_see_hidden(), UOExecutorModule::mf_SendEvent(), oldBuyHandler(), oldSellHandler(), and sellhandler().
Here is the call graph for this function:
Here is the caller graph for this function:| BObjectImp * NPC::set_script_member | ( | const char * | membername, |
| int | value | ||
| ) | [virtual] |
id test
Reimplemented from Character.
Definition at line 2460 of file uoscrobj.cpp.
References getKnownObjMember(), ObjMember::id, and set_script_member_id().
Here is the call graph for this function:| BObjectImp * NPC::set_script_member | ( | const char * | membername, |
| const std::string & | value | ||
| ) | [virtual] |
id test
Reimplemented from Character.
Definition at line 2434 of file uoscrobj.cpp.
References getKnownObjMember(), ObjMember::id, and set_script_member_id().
Here is the call graph for this function:| BObjectImp * NPC::set_script_member_id | ( | const int | id, |
| int | value | ||
| ) | [virtual] |
Reimplemented from Character.
Definition at line 2443 of file uoscrobj.cpp.
References MBR_RUN_SPEED, MBR_SAVEONEXIT, MBR_SPEECH_COLOR, MBR_SPEECH_FONT, MBR_USE_ADJUSTMENTS, run_speed, UObject::saveonexit(), Character::set_script_member_id(), speech_color_, speech_font_, and use_adjustments.
Referenced by set_script_member().
Here is the call graph for this function:
Here is the caller graph for this function:| BObjectImp * NPC::set_script_member_id | ( | const int | id, |
| const std::string & | value | ||
| ) | [virtual] |
Reimplemented from Character.
Definition at line 2422 of file uoscrobj.cpp.
References MBR_SCRIPT, script, and Character::set_script_member_id().
Here is the call graph for this function:| void NPC::start_script | ( | ) |
Definition at line 621 of file npc.cpp.
References Executor::addModule(), UOExecutorModule::attached_npc_, create_script_executor(), ex, find_script2(), ref_ptr< T >::get(), hexint(), UObject::name(), NPCExecutorModule, passert, NpcTemplate::pkg, schedule_executor(), script, UObject::serial, Executor::setProgram(), template_, and Character::UOExecutorModule.
Referenced by on_death(), readNpcProperties(), and restart_script().
Here is the call graph for this function:
Here is the caller graph for this function:| void NPC::stop_scripts | ( | ) | [protected] |
Definition at line 121 of file npc.cpp.
References deschedule_executor(), and ex.
Referenced by ~NPC().
Here is the call graph for this function:
Here is the caller graph for this function:friend class NPCExecutorModule [friend] |
Definition at line 121 of file npc.h.
Referenced by start_script().
struct { ... } NPC::anchor [private] |
Referenced by anchor_allows_move(), NPCExecutorModule::mf_SetAnchor(), NPC(), and printDebugProperties().
| unsigned short NPC::damaged_sound |
Definition at line 112 of file npc.h.
Referenced by Character::do_imhit_effects(), and readNpcProperties().
| unsigned short NPC::dstart |
Definition at line 149 of file npc.h.
Referenced by NPCExecutorModule::mf_SetAnchor().
ElementDamages NPC::element_damage_ [private] |
Definition at line 139 of file npc.h.
Referenced by loadDamages(), printProperties(), and reset_element_damage().
Resistances NPC::element_resist_ [private] |
Definition at line 138 of file npc.h.
Referenced by loadResistances(), printProperties(), and reset_element_resist().
| bool NPC::enabled |
Definition at line 146 of file npc.h.
Referenced by NPCExecutorModule::mf_SetAnchor().
UOExecutor* NPC::ex [protected] |
Definition at line 116 of file npc.h.
Referenced by apply_raw_damage_hundredths(), can_accept_event(), get_script_member_id(), inform_criminal(), inform_disengaged(), inform_engaged(), inform_enteredarea(), inform_imoved(), inform_leftarea(), inform_moved(), on_death(), on_ghost_pc_spoke(), on_pc_spoke(), restart_script(), send_event(), start_script(), stop_scripts(), and NPCExecutorModule::~NPCExecutorModule().
UOExecutor* NPC::give_item_ex [protected] |
CharacterRef NPC::master_ [private] |
Definition at line 143 of file npc.h.
Referenced by can_be_renamed_by(), get_script_member_id(), master(), printProperties(), readNpcProperties(), repsys_on_attack(), repsys_on_damage(), repsys_on_help(), and script_method_id().
unsigned short NPC::npc_ar_ [private] |
Definition at line 137 of file npc.h.
Referenced by ar(), armor_absorb_damage(), get_hitscript_params(), loadResistances(), and printProperties().
| unsigned short NPC::psub |
Definition at line 150 of file npc.h.
Referenced by NPCExecutorModule::mf_SetAnchor().
| unsigned short NPC::run_speed |
Definition at line 114 of file npc.h.
Referenced by get_script_member_id(), NPCExecutorModule::move_self(), printProperties(), readNpcProperties(), and set_script_member_id().
std::string NPC::script [private] |
Definition at line 135 of file npc.h.
Referenced by get_script_member_id(), printProperties(), readNpcProperties(), restart_script(), set_script_member_id(), and start_script().
unsigned short NPC::speech_color_ [private] |
Definition at line 152 of file npc.h.
Referenced by get_script_member_id(), printProperties(), readNpcProperties(), NPCExecutorModule::say(), NPCExecutorModule::SayUC(), and set_script_member_id().
unsigned short NPC::speech_font_ [private] |
Definition at line 153 of file npc.h.
Referenced by get_script_member_id(), printProperties(), readNpcProperties(), NPCExecutorModule::say(), NPCExecutorModule::SayUC(), and set_script_member_id().
const NpcTemplate& NPC::template_ [private] |
Definition at line 144 of file npc.h.
Referenced by custom_script_method(), get_script_member_id(), hilite_color_idx(), intrinsic_weapon(), name_color(), readNpcProperties(), and start_script().
std::string NPC::template_name [protected] |
Definition at line 119 of file npc.h.
Referenced by get_script_member_id(), on_death(), printOn(), readNpcProperties(), and readProperties().
| bool NPC::use_adjustments |
Definition at line 113 of file npc.h.
Referenced by get_script_member_id(), NPCExecutorModule::move_self(), printProperties(), readNpcProperties(), and set_script_member_id().
| unsigned short NPC::x |
Reimplemented from UObject.
Definition at line 147 of file npc.h.
Referenced by anchor_allows_move(), could_move(), inform_imoved(), inform_moved(), UOExecutorModule::mf_SendBuyWindow(), NPCExecutorModule::mf_SetAnchor(), NPCExecutorModule::move(), npc_path_blocked(), NPCExecutorModule::position(), and OSExecutorModule::signal_event().
| unsigned short NPC::y |
Reimplemented from UObject.
Definition at line 148 of file npc.h.
Referenced by anchor_allows_move(), could_move(), inform_imoved(), inform_moved(), UOExecutorModule::mf_SendBuyWindow(), NPCExecutorModule::mf_SetAnchor(), NPCExecutorModule::move(), npc_path_blocked(), NPCExecutorModule::position(), and OSExecutorModule::signal_event().