Rework all nodes displaying text according to new font_api

This commit is contained in:
Pierre-Yves Rollo
2018-07-13 20:41:53 +02:00
parent e51afb851c
commit 8c7557e45d
8 changed files with 233 additions and 234 deletions

View File

@ -128,15 +128,15 @@ local function place_entities(pos)
for entity_name, props in pairs(ndef.display_entities) do
local depth = clip_pos_prop(props.depth)
local height = clip_pos_prop(props.height)
local right = clip_pos_prop(props.right)
local top = clip_pos_prop(props.top)
if not objrefs[entity_name] then
objrefs[entity_name] = minetest.add_entity(pos, entity_name)
end
objrefs[entity_name]:setpos({
x = pos.x - values.dx * depth + values.rx * right,
y = pos.y + height,
y = pos.y - top,
z = pos.z - values.dz * depth + values.rz * right})
objrefs[entity_name]:setyaw(values.yaw)
@ -268,4 +268,4 @@ minetest.register_lbm({
})
-- Compatibility
display_lib = display_api
display_lib = display_api