Add trust check, disable model if untrusted
This commit is contained in:
parent
f109c763c1
commit
7f64ee43c9
@ -6,7 +6,7 @@ TEXTURE_HEIGHT = 128
|
||||
|
||||
-- local state variables (do not access within pings) --
|
||||
armor_enabled=true
|
||||
vanilla_enabled=true
|
||||
vanilla_enabled=false
|
||||
|
||||
-- utility functions -- {{{
|
||||
--- dump table --
|
||||
@ -205,9 +205,15 @@ function player_init()
|
||||
old_health=player.getHealth()
|
||||
end
|
||||
-- Initial configuration --
|
||||
if meta.getCanModifyVanilla() then
|
||||
for key, value in pairs(vanilla_model) do
|
||||
value.setEnabled(false)
|
||||
end
|
||||
else
|
||||
for _, v in pairs(model) do
|
||||
v.setEnabled(false)
|
||||
end
|
||||
end
|
||||
vanilla_model.CAPE.setEnabled(true)
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user