summaryrefslogtreecommitdiff
path: root/src/resources/skill
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-08-08 00:38:31 +0300
committerAndrei Karas <akaras@inbox.ru>2017-08-08 00:38:31 +0300
commit344efb2009b8c6d329a6d19dd45ed49076252710 (patch)
tree2e5c1a7d9484e1cc3bfedac7b03c7146be442896 /src/resources/skill
parentfa4c5d79b04a319550996c48448cd799fe7fde56 (diff)
downloadplus-344efb2009b8c6d329a6d19dd45ed49076252710.tar.gz
plus-344efb2009b8c6d329a6d19dd45ed49076252710.tar.bz2
plus-344efb2009b8c6d329a6d19dd45ed49076252710.tar.xz
plus-344efb2009b8c6d329a6d19dd45ed49076252710.zip
Add into skill context menu for add shortcut.
Also add chat command for add skill shortcut by skill id into free slot.
Diffstat (limited to 'src/resources/skill')
-rw-r--r--src/resources/skill/skillinfo.cpp8
-rw-r--r--src/resources/skill/skillinfo.h2
2 files changed, 10 insertions, 0 deletions
diff --git a/src/resources/skill/skillinfo.cpp b/src/resources/skill/skillinfo.cpp
index 3c74fcaa9..3f6a50eb6 100644
--- a/src/resources/skill/skillinfo.cpp
+++ b/src/resources/skill/skillinfo.cpp
@@ -194,3 +194,11 @@ SkillData *SkillInfo::getData1(const int lev) const
return (*dataMap.begin()).second;
return (*it).second;
}
+
+std::string SkillInfo::toDataStr() const
+{
+ return strprintf("%d %d %d",
+ CAST_S32(customCastType),
+ customOffsetX,
+ customOffsetY);
+}
diff --git a/src/resources/skill/skillinfo.h b/src/resources/skill/skillinfo.h
index 391a19912..c07b3209f 100644
--- a/src/resources/skill/skillinfo.h
+++ b/src/resources/skill/skillinfo.h
@@ -98,6 +98,8 @@ struct SkillInfo final
|| type == SkillType::Self
|| type == SkillType::Support;
}
+
+ std::string toDataStr() const A_WARN_UNUSED;
};
typedef STD_VECTOR<SkillInfo*> SkillList;