Пример #1
0
        private static bool CreateInstance(out IYiScript script)
        {
            var appdomain = AppDomainFactory.CreateAppDomain(FolderName);

            script = AppDomainFactory.InstantiatePlugin(Environment.CurrentDirectory + "\\" + CachedPath, appdomain);
            return(script != null);
        }
Пример #2
0
Файл: Script.cs Проект: Pircs/Yi
 public bool Compile()
 {
     _script = ScriptEngine.CompileFolder(Environment.CurrentDirectory + "\\Scripts\\" + FolderName);
     if (_script == null)
     {
         Output.WriteLine($"{FolderName} failed to load.");
         return(false);
     }
     Activate();
     YiCore.CompactLoh();
     return(true);
 }