init (again)

i accidentally [doxxed myself](https://github.com/JannisX11/blockbench/issues/1322), thanks blockbench!
This commit is contained in:
Reid 2025-03-15 15:28:46 -07:00
commit d1809b35ee
Signed by: reidlab
GPG key ID: 6C9EAA3364F962C8
20 changed files with 2363 additions and 0 deletions

18
scripts/wheels/main.lua Normal file
View file

@ -0,0 +1,18 @@
local toggles = require("scripts.wheels.toggles")
local wheels = {
toggles
}
for i, v in pairs(wheels) do
if i == 1 then action_wheel:setPage(v) end
if #wheels ~= 1 then
v:newAction()
:title("to next page")
:item("minecraft:arrow")
:onLeftClick(function ()
local index = (i + 1) > #wheels and 1 or (i + 1)
action_wheel:setPage(wheels[index])
end)
end
end

View file

@ -0,0 +1,14 @@
local toggles = action_wheel:newPage()
function pings.toggleArmor(state)
vanilla_model.ARMOR:setVisible(state)
end
local toggle_armor = toggles:newAction()
:setToggled(false)
:setOnToggle(pings.toggleArmor)
:title("toggle armor")
:item("red_wool")
:toggleItem("green_wool")
return toggles