foxygit / fake-08-xbox360 Log in
commit 593030de29dffd8255008aa9d73f3cb9c4b5fe71
Author:     jtothebell <j.to.the.bell@gmail.com>
AuthorDate: Mon Sep 28 17:51:37 2020 -0600
Commit:     jtothebell <j.to.the.bell@gmail.com>
CommitDate: Mon Sep 28 17:51:37 2020 -0600

    wire up stubbed stat function to fix crash
---
 source/vm.cpp | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/source/vm.cpp b/source/vm.cpp
index a261583..3162aff 100644
--- a/source/vm.cpp
+++ b/source/vm.cpp
@@ -177,11 +177,11 @@ bool Vm::loadCart(Cart* cart) {
     lua_register(_luaState, "time", time);
     lua_register(_luaState, "t", time);

-    //stubbed in audio:
+    //audio:
     lua_register(_luaState, "music", music);
     lua_register(_luaState, "sfx", sfx);

-    //stubbed in memory
+    //memory
     lua_register(_luaState, "cstore", cstore);
     lua_register(_luaState, "memcpy", api_memcpy);
     lua_register(_luaState, "memset", api_memset);
@@ -193,13 +193,14 @@ bool Vm::loadCart(Cart* cart) {
     lua_register(_luaState, "poke4", poke4);
     lua_register(_luaState, "reload", reload);

-    //stubbed in cart data
+    //cart data
     lua_register(_luaState, "cartdata", cartdata);
     lua_register(_luaState, "dget", dget);
     lua_register(_luaState, "dset", dset);

     //
     lua_register(_luaState, "printh", printh);
+    lua_register(_luaState, "stat", stat);

     //system
     lua_register(_luaState, "__listcarts", listcarts);