mirror of
https://github.com/pyrollo/display_modpack.git
synced 2024-12-26 06:07:29 +01:00
Added display_lib.entity_spacing variable to centralize entity spacing.
This commit is contained in:
parent
a71ae8e013
commit
ea36ed50d8
@ -19,6 +19,11 @@
|
||||
|
||||
display_lib = {}
|
||||
|
||||
-- Prefered gap between node and entity
|
||||
-- Entity positionment is up to mods but it is a good practice to use this
|
||||
-- variable as spacing between entity and node
|
||||
display_lib.entity_spacing = 0.002
|
||||
|
||||
-- Miscelaneous values depending on wallmounted param2
|
||||
local wallmounted_values = {
|
||||
[0]={dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0}, -- Should never be used
|
||||
|
@ -158,7 +158,7 @@ function signs.register_sign(mod, name, model)
|
||||
display_entities = {
|
||||
["signs:display_text"] = {
|
||||
on_display_update = font_lib.on_display_update,
|
||||
depth = 0.499 - model.depth,
|
||||
depth = 0.5 - display_lib.entity_spacing - model.depth,
|
||||
size = { x = model.width, y = model.height },
|
||||
resolution = { x = 64, y = 64 },
|
||||
maxlines = 1,
|
||||
|
@ -59,7 +59,7 @@ for i, material in ipairs(steles.materials) do
|
||||
display_entities = {
|
||||
["steles:text"] = {
|
||||
on_display_update = font_lib.on_display_update,
|
||||
depth = -2/16-0.001, height = 2/16,
|
||||
depth = -2/16 - display_lib.entity_spacing, height = 2/16,
|
||||
size = { x = 14/16, y = 12/16 },
|
||||
resolution = { x = 11, y = 5 },
|
||||
maxlines = 3,
|
||||
|
Loading…
Reference in New Issue
Block a user