Voxelis/mods/BLOCKS/vox_overworld_blocks/init.lua

123 lines
4.3 KiB
Lua
Raw Normal View History

---------------------------------------------------------------------------
-- Voxelis - Voxel survival sandbox for Luanti
-- Copyright (C) 2024 Mad Star Studio LLC
--
-- This program is free software; you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation; either version 3 of the License, or
-- (at your option) any later version.
--
-- You should have received a copy of the GNU General Public License along
-- with this program; if not, see <http://www.gnu.org/licenses/>.
---------------------------------------------------------------------------
2024-12-10 20:24:11 -08:00
-- -------------------------------------------------------------------------- --
-- Blocks --
-- -------------------------------------------------------------------------- --
2024-12-10 20:24:11 -08:00
-- ----------------------------- Terrain Surface ---------------------------- --
-- Grass
core.register_node("vox_overworld_blocks:grass", {
2024-12-10 17:27:41 -08:00
description = "Grass Block",
2024-12-10 17:03:00 -08:00
tiles = {"vox_grass.png"},
groups = {cracky = 3}
})
2024-12-10 20:24:11 -08:00
core.register_alias("grass", "vox_overworld_blocks:grass")
core.register_alias("default:dirt_with_grass" , "vox_overworld_blocks:grass")
2024-12-10 17:27:41 -08:00
2024-12-10 20:24:11 -08:00
-- Dirt
core.register_node("vox_overworld_blocks:dirt", {
description = "Dirt",
tiles = {"vox_dirt.png"},
groups = {crumbly = 3}
2024-12-10 17:27:41 -08:00
})
2024-12-10 20:24:11 -08:00
core.register_alias("dirt", "vox_overworld_blocks:dirt")
2024-12-10 17:27:41 -08:00
2024-12-10 19:58:35 -08:00
-- Sand
-- (I don't like sand. It's coarse and rough and irritating and it gets everywhere.)
2024-12-10 20:24:11 -08:00
core.register_node("vox_overworld_blocks:sand", {
2024-12-10 19:58:35 -08:00
description = "Sand",
tiles = {"vox_sand.png"},
groups = {crumbly = 3}
2024-12-10 17:27:41 -08:00
})
2024-12-10 20:24:11 -08:00
core.register_alias("sand", "vox_overworld_blocks:sand")
core.register_alias("default:sand", "vox_overworld_blocks:sand")
-- -------------------------------- Minerals -------------------------------- --
core.register_node("vox_overworld_blocks:stone", {
description = "Stone",
tiles = {"vox_stone.png"},
groups = {cracky = 2}
})
core.register_alias("stone", "vox_overworld_blocks:stone")
core.register_alias("mapgen_stone", "vox_overworld_blocks:stone")
-- core.register_alias("default:stone", "vox_overworld_blocks:stone")
2024-12-10 19:58:35 -08:00
2024-12-10 17:27:41 -08:00
-- Water
2024-12-10 20:24:11 -08:00
core.register_node("vox_overworld_blocks:water_source", {
2024-12-10 17:27:41 -08:00
description = "Water Source",
drawtype = "liquid",
tiles = {
{
name = "vox_water.png",
animation = {
type = "vertical_frames",
aspect_w = 16,
aspect_h = 16,
length = 2.0
}
}
},
2024-12-10 19:58:35 -08:00
alpha = 128,
2024-12-10 17:27:41 -08:00
paramtype = "light",
walkable = false,
pointable = false,
diggable = false,
buildable_to = true,
liquidtype = "source",
2024-12-10 20:24:11 -08:00
liquid_alternative_flowing = "vox_overworld_blocks:water_flowing",
liquid_alternative_source = "vox_overworld_blocks:water_source",
2024-12-10 17:27:41 -08:00
liquid_viscosity = 1,
post_effect_color = {a = 103, r = 30, g = 60, b = 90}
})
2024-12-10 20:24:11 -08:00
core.register_alias("water_source", "vox_overworld_blocks:water_source")
core.register_alias("default:river_water", "vox_overworld_blocks:water_source")
core.register_alias("mapgen_water_source", "vox_overworld_blocks:water_source")
-- -------------------------------------------------------------------------- --
-- Liquids --
-- -------------------------------------------------------------------------- --
2024-12-10 17:27:41 -08:00
2024-12-10 20:24:11 -08:00
core.register_node("vox_overworld_blocks:water_flowing", {
2024-12-10 17:27:41 -08:00
description = "Flowing Water",
drawtype = "flowingliquid",
tiles = {"vox_water.png"},
special_tiles = {
{
name = "vox_water.png",
backface_culling = false,
animation = {
type = "vertical_frames",
aspect_w = 16,
aspect_h = 16,
length = 0.8
}
}
},
alpha = 160,
paramtype = "light",
walkable = false,
pointable = false,
diggable = false,
buildable_to = true,
liquidtype = "flowing",
2024-12-10 20:24:11 -08:00
liquid_alternative_flowing = "vox_overworld_blocks:water_flowing",
liquid_alternative_source = "vox_overworld_blocks:water_source",
2024-12-10 17:27:41 -08:00
liquid_viscosity = 1,
post_effect_color = {a = 103, r = 30, g = 60, b = 90}
})
2024-12-10 20:24:11 -08:00
core.register_alias("water_flowing", "vox_overworld_blocks:water_flowing")