forked from hkc/cc-stuff
little stuff
This commit is contained in:
parent
d543f68947
commit
4930ea6645
|
@ -2,7 +2,11 @@
|
|||
"repository": "https://git.salushnes.solutions/hkc/cc-stuff/raw/branch/master/augment",
|
||||
"files": [
|
||||
{
|
||||
"path": "startup",
|
||||
"path": "wsvpn.lua",
|
||||
"src": "wsvpn.lua"
|
||||
},
|
||||
{
|
||||
"path": "startup.lua",
|
||||
"src": "startup.lua"
|
||||
},
|
||||
{
|
||||
|
|
|
@ -45,7 +45,7 @@ local function safeset(func, name, old)
|
|||
if func then
|
||||
local s, res = pcall(func)
|
||||
if not s then
|
||||
print("ERR: " .. name .. " failed: " .. res)
|
||||
printError("ERR: " .. name .. " failed: " .. res)
|
||||
else
|
||||
return res
|
||||
end
|
||||
|
@ -60,10 +60,7 @@ parallel.waitForAll(function()
|
|||
local ev = { os.pullEvent("exit") }
|
||||
if ev[1] == "exit" then
|
||||
_G._running = false
|
||||
local oldc = term.getTextColor()
|
||||
term.setTextColor(colors.red)
|
||||
print("Caught exit event, shutting down...")
|
||||
term.setTextColor(oldc)
|
||||
printError("Caught exit event, shutting down...")
|
||||
break
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
return function()
|
||||
while _G._running do
|
||||
local ev = { os.pullEvent() }
|
||||
if ev[1] == "key" and ev[2] == keys.q then
|
||||
if ev[1] == "key" and ev[2] == keys.f4 then
|
||||
os.queueEvent("exit")
|
||||
break
|
||||
elseif ev[1] == "timer" or ev[1] == "plethora_task" then
|
||||
|
|
|
@ -21,6 +21,7 @@ return function()
|
|||
cache[id].cube.setAlpha(0x20)
|
||||
cache[id].cube.setDepthTested(false)
|
||||
cache[id].frame.setDepthTested(false)
|
||||
|
||||
cache[id].cube.setPosition(entity.x - 0.25, entity.y - 0.25, entity.z - 0.25)
|
||||
cache[id].frame.setPosition(entity.x, entity.y, entity.z)
|
||||
cache[id].text.setAlpha(0xFF)
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
../wsvpn.lua
|
Loading…
Reference in New Issue