mirror of
https://github.com/scp-fs2open/fs2open.github.com.git
synced 2026-11-08 17:48:46 -10:00
This will automatically call the destructor of a type of Lua calls the garbage collector for an object of that type. This is the last step towards fully supporting non-trivial objects in the Lua API and all previous workarounds have been removed.
26 lines
433 B
C++
26 lines
433 B
C++
#pragma once
|
|
|
|
#include "scripting/ade_api.h"
|
|
|
|
#include "cutscene/player.h"
|
|
|
|
namespace scripting {
|
|
namespace api {
|
|
|
|
class movie_player_h {
|
|
std::unique_ptr<cutscene::Player> _player;
|
|
|
|
public:
|
|
movie_player_h();
|
|
explicit movie_player_h(std::unique_ptr<cutscene::Player>&& player);
|
|
|
|
cutscene::Player* player();
|
|
|
|
bool isValid() const;
|
|
};
|
|
|
|
DECLARE_ADE_OBJ(l_MoviePlayer, movie_player_h);
|
|
|
|
} // namespace api
|
|
} // namespace scripting
|