summaryrefslogtreecommitdiff
path: root/src/resources/npcdb.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-06-08 00:43:48 +0300
committerAndrei Karas <akaras@inbox.ru>2012-06-08 00:43:48 +0300
commitdbc3b324a0c5dcb1a0ee29b289e71423a06e85fd (patch)
treef7cda00f7415c35fb2a9e4466a751d18852070bf /src/resources/npcdb.cpp
parentcbb805a1922e3423fdaae88242835fb717a903bf (diff)
downloadplus-dbc3b324a0c5dcb1a0ee29b289e71423a06e85fd.tar.gz
plus-dbc3b324a0c5dcb1a0ee29b289e71423a06e85fd.tar.bz2
plus-dbc3b324a0c5dcb1a0ee29b289e71423a06e85fd.tar.xz
plus-dbc3b324a0c5dcb1a0ee29b289e71423a06e85fd.zip
Add to npc option targetSelection to allow/disallow npc selection.
Diffstat (limited to 'src/resources/npcdb.cpp')
-rw-r--r--src/resources/npcdb.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/resources/npcdb.cpp b/src/resources/npcdb.cpp
index 832fa26d6..26f5e53cb 100644
--- a/src/resources/npcdb.cpp
+++ b/src/resources/npcdb.cpp
@@ -38,6 +38,8 @@ namespace
bool mLoaded = false;
}
+extern int serverVersion;
+
void NPCDB::load()
{
if (mLoaded)
@@ -70,6 +72,12 @@ void NPCDB::load()
BeingInfo *currentInfo = new BeingInfo;
+ if (serverVersion > 0)
+ {
+ currentInfo->setTargetSelection(XML::getProperty(
+ npcNode, "targetSelection", true));
+ }
+
currentInfo->setTargetCursorSize(XML::getProperty(npcNode,
"targetCursor", "medium"));