append output given to color craft helper if prefix/suffix are used

(if any; allows specifying an item count/yield for the recipe)
This commit is contained in:
Vanessa Dannenberg
2018-09-12 20:26:23 -04:00
parent 4b88997360
commit 078a998d29
2 changed files with 7 additions and 6 deletions

View File

@ -265,18 +265,19 @@ local function register_c(craft, hue, sat, val)
recipe = string.gsub(recipe, "NEUTRAL_NODE", craft.neutral_node)
local newrecipe = minetest.deserialize(recipe)
local output = craft.output
local coutput = craft.output or ""
local output = coutput
if craft.output_prefix then
if craft.palette ~= "split" then
output = craft.output_prefix..color..craft.output_suffix
output = craft.output_prefix..color..craft.output_suffix..coutput
else
if hue == "white" or hue == "black" or string.find(hue, "grey") then
output = craft.output_prefix.."grey"..craft.output_suffix
output = craft.output_prefix.."grey"..craft.output_suffix..coutput
elseif hue == "pink" then
dye = "dye:light_red"
output = craft.output_prefix.."red"..craft.output_suffix
output = craft.output_prefix.."red"..craft.output_suffix..coutput
else
output = craft.output_prefix..hue..craft.output_suffix
output = craft.output_prefix..hue..craft.output_suffix..coutput
end
end
end