Advertisement
CriShoux

wild revolver thin wall

Sep 29th, 2019
506
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.89 KB | None | 0 0
  1. local function getMap()
  2. local map
  3.  
  4. for i, v in pairs(game:GetService("Workspace"):GetChildren()) do
  5. if v:IsA("Folder") and v.Name ~= "PlayerData" and v.Name ~= "Lobbies" then
  6. map = v
  7. end
  8. end
  9.  
  10. return map
  11. end
  12.  
  13. local mt = getrawmetatable(game)
  14. local oldNamecall = mt.__namecall
  15. if setreadonly then setreadonly(mt, false) else make_writeable(mt, true) end
  16. local namecallMethod = getnamecallmethod or get_namecall_method
  17. local newClose = newcclosure or function(f) return f end
  18.  
  19. mt.__namecall = newClose(function(...)
  20. local method = namecallMethod()
  21. local args = {...}
  22.  
  23. if tostring(method) == "FindPartOnRayWithIgnoreList" then
  24. table.insert(args[3], getMap())
  25. return oldNamecall(unpack(args))
  26. end
  27.  
  28. return oldNamecall(...)
  29. end)
  30.  
  31. if setreadonly then setreadonly(mt, true) else make_writeable(mt, false) end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement