require overright

This commit is contained in:
Cooldude2606
2019-08-09 16:44:27 +01:00
parent 6bab92f87f
commit 129b39bbb9
2 changed files with 12 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
local loaded = _G.package.loaded
local raw_require = require
function require(path)
return loaded[path] or error('Can only require files at runtime that have been required in the control stage.', 2)
end
return raw_require