Skill.cpp 1021 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. /*
  2. * api/Skill.cpp, part of VCMI engine
  3. *
  4. * Authors: listed in file AUTHORS in main folder
  5. *
  6. * License: GNU General Public License v2.0 or later
  7. * Full text of license available in license.txt file, in main folder
  8. *
  9. */
  10. #include "StdInc.h"
  11. #include "Skill.h"
  12. #include "Registry.h"
  13. #include "../LuaStack.h"
  14. #include "../LuaCallWrapper.h"
  15. VCMI_LIB_NAMESPACE_BEGIN
  16. namespace scripting
  17. {
  18. namespace api
  19. {
  20. VCMI_REGISTER_CORE_SCRIPT_API(SkillProxy, "Skill");
  21. const std::vector<SkillProxy::CustomRegType> SkillProxy::REGISTER_CUSTOM =
  22. {
  23. {"getIconIndex", LuaMethodWrapper<Skill, decltype(&Entity::getIconIndex), &Entity::getIconIndex>::invoke, false},
  24. {"getIndex", LuaMethodWrapper<Skill, decltype(&Entity::getIndex), &Entity::getIndex>::invoke, false},
  25. {"getJsonKey", LuaMethodWrapper<Skill, decltype(&Entity::getJsonKey), &Entity::getJsonKey>::invoke, false},
  26. {"getName", LuaMethodWrapper<Skill, decltype(&Entity::getNameTranslated), &Entity::getNameTranslated>::invoke, false},
  27. };
  28. }
  29. }
  30. VCMI_LIB_NAMESPACE_END