mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2026-04-24 11:02:14 +00:00
fix nil objects crashing parts of the game
This commit is contained in:
parent
9d1776410c
commit
ac71f841dc
1 changed files with 0 additions and 2 deletions
|
|
@ -150,7 +150,6 @@ bool smlua_is_cobject(lua_State* L, int index, UNUSED u16 lot) {
|
|||
|
||||
void* smlua_to_cobject(lua_State* L, int index, u16 lot) {
|
||||
s32 indexType = lua_type(L, index);
|
||||
if (indexType == LUA_TNIL) { return NULL; }
|
||||
if (indexType != LUA_TUSERDATA) {
|
||||
LOG_LUA_LINE("smlua_to_cobject received improper type '%d'", indexType);
|
||||
gSmLuaConvertSuccess = false;
|
||||
|
|
@ -177,7 +176,6 @@ void* smlua_to_cobject(lua_State* L, int index, u16 lot) {
|
|||
|
||||
void* smlua_to_cpointer(lua_State* L, int index, u16 lvt) {
|
||||
s32 indexType = lua_type(L, index);
|
||||
if (indexType == LUA_TNIL) { return NULL; }
|
||||
if (indexType != LUA_TUSERDATA) {
|
||||
LOG_LUA_LINE("smlua_to_cpointer received improper type '%d'", indexType);
|
||||
gSmLuaConvertSuccess = false;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue