Forum > Coding >

Fake 'readfile' function.

clxyify

clxydev

Posts: 6

Threads: 2

Joined: Apr, 2022

Reputation: 0

Posted

This is 'readfile' in C#, and this is 100% fake and its just another method for the lil kiddies who are new to exploiting and dont know how to use readfile. 

 

This is original readfile-> 

print(readfile("idk.txt")) --or .lua doesnt matter

 

Heres the fake readfile code (C#):

public void FakeReadfile(string forthepplwhocantbuyfilefunctions)//-> this is the files root directory
{
      if (File.Exists(forthepplwhocantbuyfilefunctions))//check if the file exists
      {
           string Filethatwasread = File.ReadAllText(forthepplwhocantbuyfilefunctions); //read the file
           API.Execute(Filethatwasread); //execute the file
      }
      else//if the file doesnt exist
      {
           API.Execute("print('No file was found with that name!')");//tell them something
      }
}

FakeReadfile("Owlhub.txt");//rename with your file
//OR if you have a 'scripts' folder directory
FakeReadfile("Scripts\\owlhub.txt");//good for scripts inside of a folder
  • 0

Posts: 1167

Threads: 72

Joined: Oct, 2019

Reputation: 89

Replied

private string ReadFile(string Path)
{
     if (string.IsNullOrEmpty(Path)  || !File.Exists(Path))
           return null;

     return File.ReadAllText(Path);
}
  • 0

clxyify

clxydev

Posts: 6

Threads: 2

Joined: Apr, 2022

Reputation: 0

Replied

Your a C# professional

  • 0

Users viewing this thread:

( Members: 0, Guests: 1, Total: 1 )