diff options
author | Stijn Buys <ingar@osirion.org> | 2013-11-03 23:35:59 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2013-11-03 23:35:59 +0000 |
commit | 8126e1941666f5dccd61e9ecc60db162049bb8ff (patch) | |
tree | 9468363f1670352ec8d5f2155cfcfa77b602d772 /src/game/base/jumppoint.cc | |
parent | fb18eff66171e855e378575b534683e4fb9c20f5 (diff) |
Added initial support for NPC patrol routes,
added support for lawfull/unlawfull factions.
Diffstat (limited to 'src/game/base/jumppoint.cc')
-rw-r--r-- | src/game/base/jumppoint.cc | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/game/base/jumppoint.cc b/src/game/base/jumppoint.cc index e1b9c7e..d173aee 100644 --- a/src/game/base/jumppoint.cc +++ b/src/game/base/jumppoint.cc @@ -40,30 +40,30 @@ JumpPoint::~JumpPoint() { } -void JumpPoint::set_targetlabel(const std::string &label) +void JumpPoint::set_target_label(const std::string &label) { - jumppoint_targetlabel.assign(label); + jumppoint_target_label.assign(label); } void JumpPoint::validate() { jumppoint_target = 0; - if (targetlabel().size() == 0) + if (target_label().size() == 0) return; - if (targetlabel().size() < 3) { - con_warn << " Jumppoint '" << label() << "' has invalid target '" << targetlabel() << "'\n"; + if (target_label().size() < 3) { + con_warn << " Jumppoint '" << label() << "' has invalid target '" << target_label() << "'\n"; return; } - size_t pos = targetlabel().find(':'); - if ((pos == std::string::npos) || (pos < 1) || (pos >= (targetlabel().size() - 1))) { - con_warn << " Jumppoint '" << label() << "' has invalid target '" << targetlabel() << "'\n"; + size_t pos = target_label().find(':'); + if ((pos == std::string::npos) || (pos < 1) || (pos >= (target_label().size() - 1))) { + con_warn << " Jumppoint '" << label() << "' has invalid target '" << target_label() << "'\n"; return; } - std::string zonelabel(targetlabel().substr(0, pos)); - std::string entitylabel(targetlabel().substr(pos + 1, targetlabel().size() - pos)); + std::string zonelabel(target_label().substr(0, pos)); + std::string entitylabel(target_label().substr(pos + 1, target_label().size() - pos)); core::Zone *targetzone = core::Zone::find(zonelabel); if (!targetzone) { |