Use updated alpha modes and add optional default dependency

This commit is contained in:
mazes-80 2022-09-05 23:43:11 +02:00 committed by GitHub
parent b206cfc8e8
commit 1fbba31ae1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 1 deletions

View File

@ -6,7 +6,7 @@ local waffles = {}
-- Return default sounds if available
waffles.default_sounds = function(name)
if default and default[name] then return default[name]() end
if minetest.global_exists("default") and default[name] then return default[name]() end
end
waffles.setting_or = function(name, default)

View File

@ -46,6 +46,7 @@ local def_base = {
description = S("Waffle Maker"),
drawtype = "mesh",
tiles = {"waffles_waffle_maker.png"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
paramtype2 = "facedir",

View File

@ -1,2 +1,3 @@
name = waffles
description = Waffles. Thats it.
optional_depends = default

View File

@ -14,6 +14,7 @@ minetest.register_node(MODNAME .. ":waffle", {
drawtype = "mesh",
mesh = "waffles_waffle.obj",
tiles = {"waffles_waffle.png"},
use_texture_alpha = "clip",
inventory_image = "waffles_waffle_inv.png",
wield_image = "waffles_waffle_inv.png",
paramtype = "light",