mirror of
https://github.com/TombEngine/TombEngine.git
synced 2025-04-30 08:47:58 +03:00

This is the first pass at wrapping an ITEM_INFO in a struct and handing it over to Lua. Many improvements should follow - this is more of a test implementation.
31 lines
709 B
C++
31 lines
709 B
C++
#pragma once
|
|
|
|
namespace sol {
|
|
class state;
|
|
template <typename T> class as_table_t;
|
|
}
|
|
|
|
|
|
class GameScriptItemInfo
|
|
{
|
|
private:
|
|
short m_num;
|
|
public:
|
|
GameScriptItemInfo(short num);
|
|
~GameScriptItemInfo();
|
|
GameScriptItemInfo& operator=(GameScriptItemInfo const& other) = delete;
|
|
GameScriptItemInfo(GameScriptItemInfo const& other) = delete;
|
|
static void Register(sol::state *);
|
|
static std::unique_ptr<GameScriptItemInfo> Create(
|
|
short hp,
|
|
short currentAnim,
|
|
short requiredAnimState,
|
|
sol::as_table_t<std::array<int, 3>> pos,
|
|
sol::as_table_t<std::array<short, 3>> rot,
|
|
sol::as_table_t<std::array<short, 8>> itemFlags,
|
|
short ocb,
|
|
byte aiBits,
|
|
short status,
|
|
bool active,
|
|
bool hitStatus);
|
|
};
|