mirror of
https://github.com/aseprite/aseprite.git
synced 2024-11-20 14:21:45 +00:00
lua: add missing get_image_from_arg() function
This commit is contained in:
parent
415a37ade0
commit
6108d2d5ad
@ -104,6 +104,7 @@ namespace app {
|
||||
doc::color_t convert_args_into_pixel_color(lua_State* L, int index);
|
||||
doc::Palette* get_palette_from_arg(lua_State* L, int index);
|
||||
doc::Image* may_get_image_from_arg(lua_State* L, int index);
|
||||
doc::Image* get_image_from_arg(lua_State* L, int index);
|
||||
doc::Cel* get_image_cel_from_arg(lua_State* L, int index);
|
||||
|
||||
} // namespace script
|
||||
|
@ -249,6 +249,11 @@ doc::Image* may_get_image_from_arg(lua_State* L, int index)
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
doc::Image* get_image_from_arg(lua_State* L, int index)
|
||||
{
|
||||
return get_obj<ImageObj>(L, index)->image.get();
|
||||
}
|
||||
|
||||
doc::Cel* get_image_cel_from_arg(lua_State* L, int index)
|
||||
{
|
||||
return get_obj<ImageObj>(L, index)->cel;
|
||||
|
Loading…
Reference in New Issue
Block a user