Files
vcmi/luascript/api/spells/Mechanics.h
T
Ivan Savenko 94a586b172 Implemented several TODO items
- Dropped incomplete attempt to add initialize() function
- Removed effectively duplicated getSpellByKey() method from API
- Fixed several Sonar warnings
2026-06-03 23:13:17 +03:00

33 lines
864 B
C++

/*
* Mechanics.h, part of VCMI engine
*
* Authors: listed in file AUTHORS in main folder
*
* License: GNU General Public License v2.0 or later
* Full text of license available in license.txt file, in main folder
*
*/
#pragma once
#include "../../LuaWrapper.h"
#include "../../../lib/spells/ISpellMechanics.h"
VCMI_LIB_NAMESPACE_BEGIN
namespace scripting::api
{
class MechanicsProxy : public RawPointerWrapper<::spells::Mechanics, MechanicsProxy>
{
public:
using Wrapper = RawPointerWrapper<::spells::Mechanics, MechanicsProxy>;
static const std::vector<typename Wrapper::CustomRegType> REGISTER_CUSTOM;
static bool ownerMatchesUnit(const ::spells::Mechanics * m, const battle::Unit * unit);
static std::string getPluralFormTextID(const ::spells::Mechanics * m, const std::string & baseTextID, int32_t count);
};
}
VCMI_LIB_NAMESPACE_END