blob: 648e1f4c6109fe546bc86085ee70435390c30793 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
if os.isadmin() then
print "I'm admin"
else
print "I'm NOT admin"
end
if os.iswow64() then
print "I'm a WOW64 process"
else
print "I'm NOT a WOW64 process"
end
function dumptable(T,t)
print '--------------------------'
print(T)
print '--------------------------'
for k,v in pairs(t)do print(k,v) end
end
if winres then
dumptable('winres', winres)
if winres.scripts then
dumptable('winres.scripts', winres.scripts)
end
end
for k,v in pairs(winres.scripts) do
package.preload[k:lower()] = function(...)
return winres.c_loader(k:upper())
end
package.preload[k:upper()] = package.preload[k:lower()]
end
dumptable('package.preload', package.preload)
dumptable('winreg', winreg)
require "helloworld"
dumptable('package.loaded', package.loaded)
|