Add comments (vim fold marker)
This commit is contained in:
parent
02c22df59c
commit
da194701f9
13
script.lua
13
script.lua
@ -25,7 +25,7 @@ for key, value in pairs(vanilla_model) do
|
|||||||
end
|
end
|
||||||
vanilla_model.CAPE.setEnabled(true)
|
vanilla_model.CAPE.setEnabled(true)
|
||||||
|
|
||||||
-- Expression change --
|
-- Expression change -- {{{
|
||||||
function getExprUV(damage, expression)
|
function getExprUV(damage, expression)
|
||||||
local u=offset_u_face+(damage*step_u_face)
|
local u=offset_u_face+(damage*step_u_face)
|
||||||
local v=offset_v_face+(expression*step_v_face)
|
local v=offset_v_face+(expression*step_v_face)
|
||||||
@ -53,8 +53,9 @@ end
|
|||||||
function resetExpression()
|
function resetExpression()
|
||||||
HEAD.setUV(getExprUV(face_damage,face_expr))
|
HEAD.setUV(getExprUV(face_damage,face_expr))
|
||||||
end
|
end
|
||||||
|
-- }}}
|
||||||
|
|
||||||
-- Action Wheel --
|
-- Action Wheel & Pings -- {{{
|
||||||
action_wheel.SLOT_1.setTitle('test expression')
|
action_wheel.SLOT_1.setTitle('test expression')
|
||||||
action_wheel.SLOT_1.setFunction(function() ping.expressionTest() end)
|
action_wheel.SLOT_1.setFunction(function() ping.expressionTest() end)
|
||||||
function ping.expressionTest()
|
function ping.expressionTest()
|
||||||
@ -68,7 +69,7 @@ action_wheel.SLOT_3.setFunction(function() ping.setArmor() end)
|
|||||||
|
|
||||||
-- Pings --
|
-- Pings --
|
||||||
--- Damage function --
|
--- Damage function --
|
||||||
function ping.oof(health)
|
function ping.oof(health) -- This is a replacement for onDamage, that function doesn't sync for some reason
|
||||||
if health <= 5 then
|
if health <= 5 then
|
||||||
setExpression(1,0)
|
setExpression(1,0)
|
||||||
end
|
end
|
||||||
@ -90,13 +91,13 @@ function ping.setArmor(enabled)
|
|||||||
value.setEnabled(armor_enabled)
|
value.setEnabled(armor_enabled)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
-- }}}
|
||||||
|
|
||||||
-- does not work on multiplayer, use ping.oof()
|
-- does not work on multiplayer, use ping.oof()
|
||||||
function onDamage(amount, source)
|
function onDamage(amount, source)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Timer (not mine lol) --
|
-- Timer (not mine lol) -- {{{
|
||||||
do
|
do
|
||||||
local timers = {}
|
local timers = {}
|
||||||
function wait(ticks,next)
|
function wait(ticks,next)
|
||||||
@ -131,6 +132,8 @@ do
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- }}}
|
||||||
|
|
||||||
|
|
||||||
-- Tick function --
|
-- Tick function --
|
||||||
function tick()
|
function tick()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user