Guest User

Untitled

a guest
Aug 17th, 2012
7,127
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -----------------------------------
  2. ---     Lua Code Obfuscator     ---
  3. ---        Povered by AvA       ---
  4. -----------------------------------
  5. local function ToByte( Code ) return Code:gsub( ".", function( Char ) return "\\" .. string.byte( Char ) end); end
  6. local function Random( V ) local a = ""; for i = V, math.random( V * 1, V * 3 ) do a = a .. " ".. ( "_" ):rep( i ) .."=_[\"".. ToByte( table.Random( { "RunStringEx", "DOF_Kill", "ColorToHSV", "DOFModeLHack", "AddOriginTpPVS", "AccessorFuncNW", "ErrorNoHalt", "GetTaskID", "LerpVector", "NewMesh", "PlayerDataUpdate", "STNDRD" } ) ) .. "\"]" end return a end
  7. local function Obfuscate( Code ) return "_=_G".. Random( 5 ) .."__=_[\"" .. ToByte( "string" ) .. "\"][\"" .. ToByte( "reverse" ) .. "\"]".. Random( 8 ) .."_[\"".. ToByte( "RunString" ) .. "\"](__\"" .. ToByte( Code:reverse() ) .. "\")".. Random( 5 ); end
  8.  
  9. local Code = [[print("Lol, hi!\nThis is my GLua obfuscator.")]];
  10. print( "--->>> " .. Code .. "\nObfuscated GLua code: \n" .. Obfuscate( Code ) .. "\nResult: \n" )
  11. _G["RunString"](Obfuscate( Code ))
RAW Paste Data