Ejemplo n.º 1
0
 /// <summary>
 /// Initializes a new instance of the LuaPlugin class
 /// </summary>
 /// <param name="filename"></param>
 internal LuaPlugin(string filename, LuaExtension luaExt, FSWatcher watcher)
 {
     // Store filename
     Filename = filename;
     this.luaExt = luaExt;
     LuaEnvironment = luaExt.LuaEnvironment;
     this.watcher = watcher;
 }
Ejemplo n.º 2
0
    void Awake()
    {
        LuaExtension.DoString("return 20 + 20");
        var result = (int)LuaExtension.ToNumber(1);

        LuaExtension.Pop(1);
        Debug.Log("result = " + result);
    }
Ejemplo n.º 3
0
 /// <summary>
 /// Initializes a new instance of the LuaPlugin class
 /// </summary>
 /// <param name="filename"></param>
 /// <param name="luaExt"></param>
 /// <param name="watcher"></param>
 internal LuaPlugin(string filename, LuaExtension luaExt, FSWatcher watcher)
 {
     // Store filename
     Filename       = filename;
     Name           = Core.Utility.GetFileNameWithoutExtension(Filename);
     this.luaExt    = luaExt;
     LuaEnvironment = luaExt.LuaEnvironment;
     this.watcher   = watcher;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the LuaPlugin class
 /// </summary>
 /// <param name="filename"></param>
 /// <param name="luaExt"></param>
 /// <param name="watcher"></param>
 internal LuaPlugin(string filename, LuaExtension luaExt, FSWatcher watcher)
 {
     // Store filename
     Filename = filename;
     Name = Core.Utility.GetFileNameWithoutExtension(Filename);
     this.luaExt = luaExt;
     LuaEnvironment = luaExt.LuaEnvironment;
     this.watcher = watcher;
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Initializes a new instance of the LuaPluginLoader class
 /// </summary>
 /// <param name="lua"></param>
 /// <param name="luaExtension"></param>
 public LuaPluginLoader(NLua.Lua lua, LuaExtension luaExtension)
 {
     LuaEnvironment = lua;
     LuaExtension = luaExtension;
 }
Ejemplo n.º 6
0
 /// <summary>
 /// Initializes a new instance of the LuaPluginLoader class
 /// </summary>
 /// <param name="lua"></param>
 /// <param name="luaExtension"></param>
 public LuaPluginLoader(NLua.Lua lua, LuaExtension luaExtension)
 {
     LuaEnvironment = lua;
     LuaExtension   = luaExtension;
 }