mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-11 05:51:51 +00:00
fix skeleton:get_texture
This commit is contained in:
parent
3ef8c60822
commit
748eb9d53a
1 changed files with 0 additions and 2 deletions
|
|
@ -62,8 +62,6 @@ static int l_set_matrix(lua::State* L) {
|
||||||
static int l_get_texture(lua::State* L) {
|
static int l_get_texture(lua::State* L) {
|
||||||
if (auto entity = get_entity(L, 1)) {
|
if (auto entity = get_entity(L, 1)) {
|
||||||
auto& skeleton = entity->getSkeleton();
|
auto& skeleton = entity->getSkeleton();
|
||||||
skeleton.textures[lua::require_string(L, 2)] =
|
|
||||||
lua::require_string(L, 3);
|
|
||||||
const auto& found = skeleton.textures.find(lua::require_string(L, 2));
|
const auto& found = skeleton.textures.find(lua::require_string(L, 2));
|
||||||
if (found != skeleton.textures.end()) {
|
if (found != skeleton.textures.end()) {
|
||||||
return lua::pushstring(L, found->second);
|
return lua::pushstring(L, found->second);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue