mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2025-12-30 12:31:41 +09:00
added format_as_temp_var
This commit is contained in:
@@ -109,6 +109,8 @@ See code for more details.
|
|||||||
* name = value retured by sudo
|
* name = value retured by sudo
|
||||||
* value (opt) = new value if making a new temp varible
|
* value (opt) = new value if making a new temp varible
|
||||||
* offset (opt) = if the base time is too short, for very big commands
|
* offset (opt) = if the base time is too short, for very big commands
|
||||||
|
* format_as_temp_var(string)
|
||||||
|
* returns the same value that sudo would with out running the function
|
||||||
* command: /server-interface
|
* command: /server-interface
|
||||||
* Run loadstring on lua code given like /c but does not break achievements
|
* Run loadstring on lua code given like /c but does not break achievements
|
||||||
* restriction = 'Admin'
|
* restriction = 'Admin'
|
||||||
@@ -42,6 +42,10 @@ function sudo(command,args,custom_return_name)
|
|||||||
return {sudo='sudo-temp-var',name=return_name}
|
return {sudo='sudo-temp-var',name=return_name}
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
--turns a string into the temp var format so that it can be used
|
||||||
|
function format_as_temp_var(string)
|
||||||
|
return {sudo='sudo-temp-var',name=tostring(string)}
|
||||||
|
end
|
||||||
--update the time on a temp var or add it as a new one
|
--update the time on a temp var or add it as a new one
|
||||||
function refresh_temp_var(name,value,offset)
|
function refresh_temp_var(name,value,offset)
|
||||||
local offset = offset or temp_var_time
|
local offset = offset or temp_var_time
|
||||||
|
|||||||
Reference in New Issue
Block a user