But did YOU know (minified)
This commit is contained in:
@@ -1 +1 @@
|
||||
utf-8
|
||||
local a;local b;if table.copy then a=table.copy(component)b=table.copy(component)else a={}b=component end;_G.componentlib={["additions"]={},["removals"]={}}a.virtual={}function a.virtual.add(a,b,c)checkArg(1,a,"string")checkArg(2,b,"string")checkArg(3,c,"table")c["address"]=a;componentlib.additions[a]={["componentType"]=b,["proxy"]=c}if componentlib.removals[a]then componentlib.removals[a]=nil end end;function a.virtual.remove(a)checkArg(1,a,"string")if componentlib.additions[a]then componentlib.additions[a]=nil else table.insert(componentlib.removals,a)end end;function a.list(a)checkArg(1,a,"string","nil")local b=table.copy(b.list(a))for c,d in pairs(componentlib.additions)do if d.componentType==a or not a then b[c]=d.componentType end end;for a,a in pairs(componentlib.removals)do b[a]=nil end;local a,c;setmetatable(b,{__call=function(b)a,c=next(b,a)return a,c end})return b end;function a.proxy(a)if componentlib.additions[a]then return componentlib.additions[a].proxy else return b.proxy(a)end end;function a.invoke(a,c,...)if componentlib.additions[a]then return componentlib.additions[a].proxy[c](...)else return b.invoke(a,c,...)end end;function a.get(b)checkArg(1,b,"string")if#b<3 then return nil,"abbreviated address must be at least 3 characters long"end;for a,c in a.list()do if a:find("^"..b)then return(a)end end;return nil,"full address not found"end;setmetatable(a,{["__index"]=function(b,b)if a.list(b)()then return a.proxy(a.list(b)())else return a[b]end end})return a
|
||||
Reference in New Issue
Block a user