Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //REMEMBER TO WATCH THE VIDEO!
- // Remember to do this in order.
- // Put this code in the beginning
- Module easyexploits = new Module();
- // Execute button
- HtmlDocument text = webBrowser1.Document;
- string scriptName = "GetText";
- object[] args = new string[0];
- object obj = text.InvokeScript(scriptName, args);
- string script = obj.ToString();
- easyexploits.ExecuteScript(script);
- // Inject button
- easyexploits.LaunchExploit();
- // Clear button
- webBrowser1.Document.InvokeScript("SetText", new object[]
- {
- ""
- });
- // Create a new file called "Functions.cs", and add this code
- public static OpenFileDialog openfiledialog = new OpenFileDialog
- {
- Filter = "Script File|*.txt;*.lua|All files (*.*)|*.*",
- FilterIndex = 1,
- RestoreDirectory = true,
- Title = "Open file"
- };
- // Open file code (REMEMBER TO ADD THE FUNCTIONS.CS CODE!
- if (Functions.openfiledialog.ShowDialog() == DialogResult.OK)
- {
- try
- {
- string MainText = File.ReadAllText(Functions.openfiledialog.FileName);
- webBrowser1.Document.InvokeScript("SetText", new object[]
- {
- MainText
- });
- }
- catch (Exception ex)
- {
- MessageBox.Show("Error: Could not read file from disk. Original error: " + ex.Message);
- Console.WriteLine("File can't be opened");
- }
- }
- // Monaco code (add this for the form load part, watch the video to see where to put it)
- WebClient wc = new WebClient
- {
- Proxy = null
- };
- try
- {
- RegistryKey registryKey = Registry.CurrentUser.OpenSubKey("SOFTWARE\\Microsoft\\Internet Explorer\\Main\\FeatureControl\\FEATURE_BROWSER_EMULATION", true);
- string friendlyName = AppDomain.CurrentDomain.FriendlyName;
- bool flag2 = registryKey.GetValue(friendlyName) == null;
- if (flag2)
- {
- registryKey.SetValue(friendlyName, 11001, RegistryValueKind.DWord);
- }
- registryKey = null;
- friendlyName = null;
- }
- catch (Exception)
- {
- }
- webBrowser1.Url = new Uri(string.Format("file:///{0}/Monaco/Monaco.html", Directory.GetCurrentDirectory()));
- webBrowser1.Document.InvokeScript("SetTheme", new string[]
- {
- "Dark"
- /*
- There are 2 Themes Dark and Light
- */
- });
- addBase();
- addMath();
- addGlobalNS();
- addGlobalV();
- addGlobalF();
- webBrowser1.Document.InvokeScript("SetText", new object[]
- {
- "-- Text here"
- });
- // Monaco code (look in the video for where to put these codes)
- rivate string defPath = Application.StartupPath + "//Monaco//"; // some varibles
- private void addIntel(string label, string kind, string detail, string insertText)
- {
- string text = "\"" + label + "\"";
- string text2 = "\"" + kind + "\"";
- string text3 = "\"" + detail + "\"";
- string text4 = "\"" + insertText + "\"";
- webBrowser1.Document.InvokeScript("AddIntellisense", new object[] // some monaco shit
- {
- label,
- kind,
- detail,
- insertText
- });
- }
- // Credits to Main_EX for this!
- private void addGlobalF()
- {
- string[] array = File.ReadAllLines(defPath + "//globalf.txt");
- foreach (string text in array)
- {
- bool flag = text.Contains(':');
- if (flag)
- {
- addIntel(text, "Function", text, text.Substring(1));
- }
- else
- {
- addIntel(text, "Function", text, text);
- }
- }
- }
- private void addGlobalV()
- {
- foreach (string text in File.ReadLines(defPath + "//globalv.txt"))
- {
- addIntel(text, "Variable", text, text);
- }
- }
- private void addGlobalNS()
- {
- foreach (string text in File.ReadLines(defPath + "//globalns.txt"))
- {
- addIntel(text, "Class", text, text);
- }
- }
- private void addMath()
- {
- foreach (string text in File.ReadLines(defPath + "//classfunc.txt"))
- {
- addIntel(text, "Method", text, text);
- }
- }
- private void addBase()
- {
- foreach (string text in File.ReadLines(defPath + "//base.txt"))
- {
- addIntel(text, "Keyword", text, text);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement