mirror of
https://github.com/minetest/minetest_game.git
synced 2025-01-03 12:00:20 +01:00
Wool mod: Remove 'basecolor', 'excolor', 'unicolor' groups
This commit is contained in:
parent
3484ff23ad
commit
6f80fd3737
@ -1,27 +1,23 @@
|
|||||||
-- This uses a trick: you can first define the recipes using all of the base
|
|
||||||
-- colors, and then some recipes using more specific colors for a few non-base
|
|
||||||
-- colors available. When crafting, the last recipes will be checked first.
|
|
||||||
|
|
||||||
local dyes = {
|
local dyes = {
|
||||||
{"white", "White", "basecolor_white"},
|
{"white", "White"},
|
||||||
{"grey", "Grey", "basecolor_grey"},
|
{"grey", "Grey"},
|
||||||
{"black", "Black", "basecolor_black"},
|
{"black", "Black"},
|
||||||
{"red", "Red", "basecolor_red"},
|
{"red", "Red"},
|
||||||
{"yellow", "Yellow", "basecolor_yellow"},
|
{"yellow", "Yellow"},
|
||||||
{"green", "Green", "basecolor_green"},
|
{"green", "Green"},
|
||||||
{"cyan", "Cyan", "basecolor_cyan"},
|
{"cyan", "Cyan"},
|
||||||
{"blue", "Blue", "basecolor_blue"},
|
{"blue", "Blue"},
|
||||||
{"magenta", "Magenta", "basecolor_magenta"},
|
{"magenta", "Magenta"},
|
||||||
{"orange", "Orange", "excolor_orange"},
|
{"orange", "Orange"},
|
||||||
{"violet", "Violet", "excolor_violet"},
|
{"violet", "Violet"},
|
||||||
{"brown", "Brown", "unicolor_dark_orange"},
|
{"brown", "Brown"},
|
||||||
{"pink", "Pink", "unicolor_light_red"},
|
{"pink", "Pink"},
|
||||||
{"dark_grey", "Dark Grey", "unicolor_darkgrey"},
|
{"dark_grey", "Dark Grey"},
|
||||||
{"dark_green", "Dark Green", "unicolor_dark_green"},
|
{"dark_green", "Dark Green"},
|
||||||
}
|
}
|
||||||
|
|
||||||
for i = 1, #dyes do
|
for i = 1, #dyes do
|
||||||
local name, desc, craft_color_group = unpack(dyes[i])
|
local name, desc = unpack(dyes[i])
|
||||||
|
|
||||||
minetest.register_node("wool:" .. name, {
|
minetest.register_node("wool:" .. name, {
|
||||||
description = desc .. " Wool",
|
description = desc .. " Wool",
|
||||||
@ -35,13 +31,11 @@ for i = 1, #dyes do
|
|||||||
minetest.register_craft{
|
minetest.register_craft{
|
||||||
type = "shapeless",
|
type = "shapeless",
|
||||||
output = "wool:" .. name,
|
output = "wool:" .. name,
|
||||||
recipe = {"group:dye," .. craft_color_group, "group:wool"},
|
recipe = {"group:dye,color_" .. name, "group:wool"},
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- Legacy
|
||||||
-- legacy
|
|
||||||
|
|
||||||
-- Backwards compatibility with jordach's 16-color wool mod
|
-- Backwards compatibility with jordach's 16-color wool mod
|
||||||
minetest.register_alias("wool:dark_blue", "wool:blue")
|
minetest.register_alias("wool:dark_blue", "wool:blue")
|
||||||
minetest.register_alias("wool:gold", "wool:yellow")
|
minetest.register_alias("wool:gold", "wool:yellow")
|
||||||
|
Loading…
Reference in New Issue
Block a user