mirror of
https://github.com/theFox6/microexpansion.git
synced 2024-08-20 21:14:05 +02:00
API: Allow texture modifiers in node registration
If using texture modifiers, you must use the full texture name.
This commit is contained in:
parent
45f3ca4732
commit
53efb78c81
12
api.lua
12
api.lua
@ -118,12 +118,14 @@ function microexpansion.register_node(itemstring, def)
|
|||||||
-- Update texture
|
-- Update texture
|
||||||
if auto_complete ~= false then
|
if auto_complete ~= false then
|
||||||
for _,i in ipairs(def.tiles) do
|
for _,i in ipairs(def.tiles) do
|
||||||
local prefix = ""
|
if #def.tiles[_]:split("^") <= 1 then
|
||||||
if def.type == "ore" then
|
local prefix = ""
|
||||||
prefix = "ore_"
|
if def.type == "ore" then
|
||||||
end
|
prefix = "ore_"
|
||||||
|
end
|
||||||
|
|
||||||
def.tiles[_] = BASENAME.."_"..prefix..i..".png"
|
def.tiles[_] = BASENAME.."_"..prefix..i..".png"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
-- Colour description
|
-- Colour description
|
||||||
|
Loading…
Reference in New Issue
Block a user