Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- note this is for roblox exploiting
- local mt = getrawmetatable(mt) -- Gets metatable of game, also bypasses __metatable error
- local mt_namecall = mt.__namecall -- Create a backup metatable of game
- do setreadonly(mt, false) end -- Makes a new scope and makes it writeable as well as readable
- mt.__namecall = newcclosure(function(self, ...) -- Wraps a function in a C (more undetectable), and assigns 2 args, the thing being called on by the method, e.g: :Destroy, :Remove, and ... as extra args
- local args = {...} -- Wraps all extra parameters in a table
- local method = table.remove(args) -- Gets the method being used, e.g: :Destroy, :Remove, always last arg.
- if self.Name == "whopie" then -- check if the object being called on by a method is named whopie
- return "OH HELLO THERE" -- return a shitty return thing
- end
- return mt_namecall(self, ...) -- returns backup, so we dont completely overwrite this whole metatable.
- end)
- -- extra information : self, is usually operating on itself..., e.g:
- local table = {ass = "cheesy"}
- function table:smellass() -- gives it a colon : which adds a secret parameter, self. it can also be : table.smellass(self), must be 1st arg
- return self.ass -- instead of table.ass, more better coding practice...
- end
- print(table:smellass())
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement