Added SHV and LemonUI to Javascript

This commit is contained in:
EntenKoeniq
2022-03-25 20:41:59 +01:00
parent 50bcfabf18
commit 20f0833795

View File

@ -1,8 +1,10 @@
using System; using System;
using System.IO; using System.IO;
using System.Linq; using System.Linq;
using System.Reflection;
using System.Collections.Generic; using System.Collections.Generic;
using Microsoft.ClearScript;
using Microsoft.ClearScript.V8; using Microsoft.ClearScript.V8;
using GTA; using GTA;
@ -56,6 +58,8 @@ namespace CoopClient
{ {
V8ScriptEngine engine = new V8ScriptEngine(); V8ScriptEngine engine = new V8ScriptEngine();
engine.AddHostObject("SHV", new HostTypeCollection(Assembly.LoadFrom("ScriptHookVDotNet3.dll")));
engine.AddHostObject("LemonUI", new HostTypeCollection(Assembly.LoadFrom("scripts\\LemonUI.SHVDN3.dll")));
engine.AddHostObject("API", new ScriptContext()); engine.AddHostObject("API", new ScriptContext());
try try