15 Add mineral waters under
|
@ -1498,6 +1498,11 @@ https://freesound.org/people/Rudmer_Rotteveel/sounds/590950/
|
||||||
|
|
||||||
- everness_water_geyser.1.ogg
|
- everness_water_geyser.1.ogg
|
||||||
|
|
||||||
|
**CC0-1.0, by Fission9**, https://freesound.org/people/Fission9/sounds/474850/
|
||||||
|
|
||||||
|
- everness_lava.1.ogg
|
||||||
|
- everness_lava.2.ogg
|
||||||
|
|
||||||
### Models
|
### Models
|
||||||
|
|
||||||
**CC-BY-SA-4.0, by SaKeL**
|
**CC-BY-SA-4.0, by SaKeL**
|
||||||
|
|
19
api.lua
|
@ -969,6 +969,8 @@ end
|
||||||
|
|
||||||
function Everness.register_ore(self, def)
|
function Everness.register_ore(self, def)
|
||||||
local _def = table.copy(def)
|
local _def = table.copy(def)
|
||||||
|
-- @TOTO using `ore` as name here will override the entry when there are multiple ore registrations for the same ore (different noise)
|
||||||
|
-- using indexed table would be more appropriate here
|
||||||
local _name = _def.ore
|
local _name = _def.ore
|
||||||
|
|
||||||
self.registered_ores[_name] = _def
|
self.registered_ores[_name] = _def
|
||||||
|
@ -2154,3 +2156,20 @@ function Everness.add_to_queue_on_generated(self, def)
|
||||||
|
|
||||||
table.insert(self.on_generated_queue, def)
|
table.insert(self.on_generated_queue, def)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function Everness.find_irecursive(table, c_id)
|
||||||
|
local found = false
|
||||||
|
|
||||||
|
for i, v in ipairs(table) do
|
||||||
|
if type(v) == 'table' then
|
||||||
|
Everness.find_irecursive(v, c_id)
|
||||||
|
end
|
||||||
|
|
||||||
|
if c_id == v then
|
||||||
|
found = true
|
||||||
|
break
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
return found
|
||||||
|
end
|
||||||
|
|
138
functions.lua
|
@ -922,6 +922,144 @@ Everness:register_abm({
|
||||||
end
|
end
|
||||||
})
|
})
|
||||||
|
|
||||||
|
-- Lava spitting
|
||||||
|
Everness:register_abm({
|
||||||
|
label = 'everness:lava_spitting',
|
||||||
|
description = 'Lava bursts in to air.',
|
||||||
|
nodenames = { 'everness:lava_source' },
|
||||||
|
neighbors = { 'air' },
|
||||||
|
interval = 10,
|
||||||
|
chance = 200,
|
||||||
|
catch_up = false,
|
||||||
|
action = function(pos, node)
|
||||||
|
local burst_colors = {
|
||||||
|
'#FF5400',
|
||||||
|
'#DD2005'
|
||||||
|
}
|
||||||
|
local partcile_time = math.random(3, 5)
|
||||||
|
|
||||||
|
-- particles
|
||||||
|
local particlespawner_def = {
|
||||||
|
amount = 10,
|
||||||
|
time = partcile_time,
|
||||||
|
minpos = vector.new(pos.x - 0.1, pos.y + 0.5, pos.z - 0.1),
|
||||||
|
maxpos = vector.new(pos.x + 0.1, pos.y + 1, pos.z + 0.1),
|
||||||
|
minvel = vector.new(0, 1, 0),
|
||||||
|
maxvel = vector.new(0, 3, 0),
|
||||||
|
minacc = vector.new(0, -3, 0),
|
||||||
|
maxacc = vector.new(0, -6, 0),
|
||||||
|
minexptime = 3,
|
||||||
|
maxexptime = 5,
|
||||||
|
minsize = 3,
|
||||||
|
maxsize = 10,
|
||||||
|
texture = ('everness_water_geyser_particle.png^[multiply:%s'):format(burst_colors[math.random(1, #burst_colors)]),
|
||||||
|
vertical = true,
|
||||||
|
collisiondetection = true,
|
||||||
|
collision_removal = true
|
||||||
|
}
|
||||||
|
local particlespawner_def2 = {
|
||||||
|
amount = 40,
|
||||||
|
time = partcile_time,
|
||||||
|
minpos = vector.new(pos.x, pos.y + 0.5, pos.z),
|
||||||
|
maxpos = vector.new(pos.x, pos.y + 1, pos.z),
|
||||||
|
minvel = vector.new(0, 1, 0),
|
||||||
|
maxvel = vector.new(0, 3, 0),
|
||||||
|
minacc = vector.new(-1, -3, -1),
|
||||||
|
maxacc = vector.new(1, -6, 1),
|
||||||
|
minexptime = 3,
|
||||||
|
maxexptime = 5,
|
||||||
|
minsize = 3,
|
||||||
|
maxsize = 10,
|
||||||
|
node = node,
|
||||||
|
vertical = true,
|
||||||
|
collisiondetection = true,
|
||||||
|
collision_removal = true
|
||||||
|
}
|
||||||
|
|
||||||
|
if minetest.has_feature({ dynamic_add_media_table = true, particlespawner_tweenable = true }) then
|
||||||
|
-- new syntax, above v5.6.0
|
||||||
|
particlespawner_def = {
|
||||||
|
amount = 10,
|
||||||
|
time = partcile_time,
|
||||||
|
size = {
|
||||||
|
min = 1,
|
||||||
|
max = 2,
|
||||||
|
},
|
||||||
|
exptime = {
|
||||||
|
min = 3,
|
||||||
|
max = 5
|
||||||
|
},
|
||||||
|
pos = {
|
||||||
|
min = vector.new(pos.x - 0.1, pos.y + 0.5, pos.z - 0.1),
|
||||||
|
max = vector.new(pos.x + 0.1, pos.y + 1, pos.z + 0.1)
|
||||||
|
},
|
||||||
|
vel = {
|
||||||
|
min = vector.new(0, 1, 0),
|
||||||
|
max = vector.new(0, 3, 0)
|
||||||
|
},
|
||||||
|
acc = {
|
||||||
|
min = vector.new(0, -3, 0),
|
||||||
|
max = vector.new(0, -6, 0)
|
||||||
|
},
|
||||||
|
texture = {
|
||||||
|
name = ('everness_water_geyser_particle.png^[multiply:%s'):format(burst_colors[math.random(1, #burst_colors)]),
|
||||||
|
scale_tween = {
|
||||||
|
10, 3,
|
||||||
|
style = 'fwd',
|
||||||
|
reps = 1
|
||||||
|
}
|
||||||
|
},
|
||||||
|
vertical = true,
|
||||||
|
collisiondetection = true,
|
||||||
|
collision_removal = true
|
||||||
|
}
|
||||||
|
|
||||||
|
particlespawner_def2 = {
|
||||||
|
amount = 40,
|
||||||
|
time = partcile_time,
|
||||||
|
size = {
|
||||||
|
min = 1,
|
||||||
|
max = 2,
|
||||||
|
},
|
||||||
|
exptime = {
|
||||||
|
min = 3,
|
||||||
|
max = 5
|
||||||
|
},
|
||||||
|
pos = {
|
||||||
|
min = vector.new(pos.x, pos.y + 0.5, pos.z),
|
||||||
|
max = vector.new(pos.x, pos.y + 1, pos.z)
|
||||||
|
},
|
||||||
|
vel = {
|
||||||
|
min = vector.new(0, 1, 0),
|
||||||
|
max = vector.new(0, 3, 0)
|
||||||
|
},
|
||||||
|
acc = {
|
||||||
|
min = vector.new(-1, -3, -1),
|
||||||
|
max = vector.new(1, -6, 1)
|
||||||
|
},
|
||||||
|
node = node,
|
||||||
|
vertical = true,
|
||||||
|
collisiondetection = true,
|
||||||
|
collision_removal = true
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
if math.random(0, 100) <=50 then
|
||||||
|
minetest.add_particlespawner(particlespawner_def2)
|
||||||
|
else
|
||||||
|
minetest.add_particlespawner(particlespawner_def)
|
||||||
|
end
|
||||||
|
|
||||||
|
minetest.sound_play({
|
||||||
|
name = 'everness_lava',
|
||||||
|
gain = 1.0
|
||||||
|
}, {
|
||||||
|
pos = pos,
|
||||||
|
max_hear_distance = 32
|
||||||
|
})
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
-- Generate bamboo tops after mineral waters biome generates decorations
|
-- Generate bamboo tops after mineral waters biome generates decorations
|
||||||
Everness:register_lbm({
|
Everness:register_lbm({
|
||||||
-- Descriptive label for profiling purposes (optional).
|
-- Descriptive label for profiling purposes (optional).
|
||||||
|
|
1
init.lua
|
@ -35,6 +35,7 @@ dofile(path .. '/bamboo.lua')
|
||||||
dofile(path .. '/functions.lua')
|
dofile(path .. '/functions.lua')
|
||||||
dofile(path .. '/trees.lua')
|
dofile(path .. '/trees.lua')
|
||||||
dofile(path .. '/vines.lua')
|
dofile(path .. '/vines.lua')
|
||||||
|
dofile(path .. '/vines_wall.lua')
|
||||||
dofile(path .. '/chests.lua')
|
dofile(path .. '/chests.lua')
|
||||||
dofile(path .. '/torches.lua')
|
dofile(path .. '/torches.lua')
|
||||||
|
|
||||||
|
|
|
@ -87,7 +87,7 @@ minetest.register_on_generated(function(minp, maxp, blockseed)
|
||||||
for _, def in ipairs(Everness.on_generated_queue) do
|
for _, def in ipairs(Everness.on_generated_queue) do
|
||||||
if def.can_run(biomemap) and def.after_write_to_map then
|
if def.can_run(biomemap) and def.after_write_to_map then
|
||||||
shared_args[def.name] = shared_args[def.name] or {}
|
shared_args[def.name] = shared_args[def.name] or {}
|
||||||
def.after_write_to_map(shared_args[def.name], gennotify)
|
def.after_write_to_map(shared_args[def.name], gennotify, rand)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -246,23 +246,6 @@ local size = { x = 7, y = 16, z = 9 }
|
||||||
local size_x = math.round(size.x / 2)
|
local size_x = math.round(size.x / 2)
|
||||||
local size_z = math.round(size.z / 2)
|
local size_z = math.round(size.z / 2)
|
||||||
|
|
||||||
local function find_irecursive(table, c_id)
|
|
||||||
local found = false
|
|
||||||
|
|
||||||
for i, v in ipairs(table) do
|
|
||||||
if type(v) == 'table' then
|
|
||||||
find_irecursive(v, c_id)
|
|
||||||
end
|
|
||||||
|
|
||||||
if c_id == v then
|
|
||||||
found = true
|
|
||||||
break
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
return found
|
|
||||||
end
|
|
||||||
|
|
||||||
local function place_decoration(pos, vm, area, data, deco_id, callback)
|
local function place_decoration(pos, vm, area, data, deco_id, callback)
|
||||||
local deco_def = minetest.registered_decorations[deco_id]
|
local deco_def = minetest.registered_decorations[deco_id]
|
||||||
|
|
||||||
|
@ -394,14 +377,14 @@ Everness:add_to_queue_on_generated({
|
||||||
-- Check for water and build nodes before replacing, this will make pools connected and will not replace already built walls from another pool near by
|
-- Check for water and build nodes before replacing, this will make pools connected and will not replace already built walls from another pool near by
|
||||||
if hi == 1
|
if hi == 1
|
||||||
and current_c_id ~= c_everness_mineral_water_source
|
and current_c_id ~= c_everness_mineral_water_source
|
||||||
and not find_irecursive(pool_build_nodes, current_c_id)
|
and not Everness.find_irecursive(pool_build_nodes, current_c_id)
|
||||||
then
|
then
|
||||||
-- build pool floor
|
-- build pool floor
|
||||||
data[ai_cub] = mineral_stone
|
data[ai_cub] = mineral_stone
|
||||||
elseif hi ~= 1
|
elseif hi ~= 1
|
||||||
and (wi == 1 or wi == width)
|
and (wi == 1 or wi == width)
|
||||||
and current_c_id ~= c_everness_mineral_water_source
|
and current_c_id ~= c_everness_mineral_water_source
|
||||||
and not find_irecursive(pool_build_nodes, current_c_id)
|
and not Everness.find_irecursive(pool_build_nodes, current_c_id)
|
||||||
then
|
then
|
||||||
-- build pool wall
|
-- build pool wall
|
||||||
data[ai_cub] = mineral_stone
|
data[ai_cub] = mineral_stone
|
||||||
|
@ -409,7 +392,7 @@ Everness:add_to_queue_on_generated({
|
||||||
and (li == 1 or li == length)
|
and (li == 1 or li == length)
|
||||||
and (wi ~= 1 or wi ~= width)
|
and (wi ~= 1 or wi ~= width)
|
||||||
and current_c_id ~= c_everness_mineral_water_source
|
and current_c_id ~= c_everness_mineral_water_source
|
||||||
and not find_irecursive(pool_build_nodes, current_c_id)
|
and not Everness.find_irecursive(pool_build_nodes, current_c_id)
|
||||||
then
|
then
|
||||||
-- build pool wall
|
-- build pool wall
|
||||||
data[ai_cub] = mineral_stone
|
data[ai_cub] = mineral_stone
|
||||||
|
|
|
@ -25,7 +25,10 @@ local y_min = Everness.settings.biomes.everness_mineral_waters_under.y_min
|
||||||
|
|
||||||
Everness:register_biome({
|
Everness:register_biome({
|
||||||
name = 'everness:mineral_waters_under',
|
name = 'everness:mineral_waters_under',
|
||||||
node_cave_liquid = 'air',
|
node_stone = 'everness:mineral_cave_stone',
|
||||||
|
node_filler = 'everness:mineral_cave_stone',
|
||||||
|
node_cave_liquid = 'everness:lava_source',
|
||||||
|
node_water = 'air',
|
||||||
node_dungeon = 'everness:mineral_stone_brick',
|
node_dungeon = 'everness:mineral_stone_brick',
|
||||||
node_dungeon_alt = 'everness:mineral_stone_brick_with_growth',
|
node_dungeon_alt = 'everness:mineral_stone_brick_with_growth',
|
||||||
node_dungeon_stair = 'stairs:stair_mineral_stone_brick',
|
node_dungeon_stair = 'stairs:stair_mineral_stone_brick',
|
||||||
|
@ -40,13 +43,40 @@ Everness:register_biome({
|
||||||
-- Ores
|
-- Ores
|
||||||
--
|
--
|
||||||
|
|
||||||
|
minetest.register_on_mods_loaded(function()
|
||||||
|
local c_mapgen_stone = minetest.get_content_id('mapgen_stone')
|
||||||
|
local mapgen_stone_itemstring = minetest.get_name_from_content_id(c_mapgen_stone)
|
||||||
|
|
||||||
|
for name, def in pairs(minetest.registered_ores) do
|
||||||
|
local wherein = def.wherein
|
||||||
|
local biomes = def.biomes
|
||||||
|
|
||||||
|
if type(def.wherein) == 'string' then
|
||||||
|
wherein = { wherein }
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Register the same ores what are defined for `mapgen_stone`
|
||||||
|
if
|
||||||
|
table.indexof(wherein, mapgen_stone_itemstring) > -1
|
||||||
|
and not biomes
|
||||||
|
then
|
||||||
|
def.wherein = { 'everness:mineral_cave_stone' }
|
||||||
|
def.biomes = { 'everness:mineral_waters_under' }
|
||||||
|
def.y_max = y_max
|
||||||
|
def.y_min = y_min
|
||||||
|
|
||||||
|
Everness:register_ore(def)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end)
|
||||||
|
|
||||||
-- Blob ore.
|
-- Blob ore.
|
||||||
-- These before scatter ores to avoid other ores in blobs.
|
-- These before scatter ores to avoid other ores in blobs.
|
||||||
|
|
||||||
Everness:register_ore({
|
Everness:register_ore({
|
||||||
ore_type = 'blob',
|
ore_type = 'blob',
|
||||||
ore = 'everness:mineral_stone',
|
ore = 'everness:mineral_stone',
|
||||||
wherein = { 'mapgen_stone' },
|
wherein = { 'everness:mineral_cave_stone' },
|
||||||
clust_scarcity = 16 * 16 * 16,
|
clust_scarcity = 16 * 16 * 16,
|
||||||
clust_size = 5,
|
clust_size = 5,
|
||||||
y_max = y_max,
|
y_max = y_max,
|
||||||
|
@ -68,9 +98,9 @@ Everness:register_ore({
|
||||||
--
|
--
|
||||||
|
|
||||||
Everness:register_decoration({
|
Everness:register_decoration({
|
||||||
name = 'everness:mineral_water_under_floors',
|
name = 'everness:mineral_waters_under_floors',
|
||||||
deco_type = 'simple',
|
deco_type = 'simple',
|
||||||
place_on = { 'default:stone' },
|
place_on = { 'everness:mineral_cave_stone' },
|
||||||
sidelen = 16,
|
sidelen = 16,
|
||||||
place_offset_y = -1,
|
place_offset_y = -1,
|
||||||
fill_ratio = 10,
|
fill_ratio = 10,
|
||||||
|
@ -83,70 +113,130 @@ Everness:register_decoration({
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Everness:register_decoration({
|
||||||
|
name = 'everness:mineral_waters_under_volcanic_spike',
|
||||||
|
deco_type = 'simple',
|
||||||
|
place_on = {
|
||||||
|
'everness:mineral_lava_stone',
|
||||||
|
'everness:mineral_cave_stone'
|
||||||
|
},
|
||||||
|
sidelen = 16,
|
||||||
|
noise_params = {
|
||||||
|
offset = -0.03,
|
||||||
|
scale = 0.09,
|
||||||
|
spread = { x = 200, y = 200, z = 200 },
|
||||||
|
seed = 329,
|
||||||
|
octaves = 3,
|
||||||
|
persist = 0.6
|
||||||
|
},
|
||||||
|
biomes = { 'everness:mineral_waters_under' },
|
||||||
|
spawn_by = 'air',
|
||||||
|
check_offset = 0,
|
||||||
|
num_spawn_by = 1,
|
||||||
|
decoration = {
|
||||||
|
'everness:marker'
|
||||||
|
},
|
||||||
|
y_max = y_max,
|
||||||
|
y_min = y_min,
|
||||||
|
flags = 'all_floors',
|
||||||
|
})
|
||||||
|
|
||||||
|
Everness:register_decoration({
|
||||||
|
name = 'everness:mineral_waters_under_lava_stone_spike',
|
||||||
|
deco_type = 'simple',
|
||||||
|
place_on = {
|
||||||
|
'everness:mineral_lava_stone',
|
||||||
|
'everness:mineral_cave_stone'
|
||||||
|
},
|
||||||
|
sidelen = 16,
|
||||||
|
noise_params = {
|
||||||
|
offset = -0.015,
|
||||||
|
scale = 0.075,
|
||||||
|
spread = { x = 200, y = 200, z = 200 },
|
||||||
|
seed = 329,
|
||||||
|
octaves = 3,
|
||||||
|
persist = 0.6
|
||||||
|
},
|
||||||
|
biomes = { 'everness:mineral_waters_under' },
|
||||||
|
decoration = {
|
||||||
|
'everness:marker'
|
||||||
|
},
|
||||||
|
y_max = y_max,
|
||||||
|
y_min = y_min,
|
||||||
|
flags = 'all_floors',
|
||||||
|
})
|
||||||
|
|
||||||
--
|
--
|
||||||
-- On Generated
|
-- On Generated
|
||||||
--
|
--
|
||||||
|
|
||||||
local function find_walls(cpos)
|
-- Get the content IDs for the nodes used
|
||||||
local is_wall = function(node)
|
local c_everness_wall_vine_cave_cyan = minetest.get_content_id('everness:wall_vine_cave_cyan')
|
||||||
return node.name ~= 'air' and node.name ~= 'ignore'
|
local c_everness_wall_vine_cave_violet = minetest.get_content_id('everness:wall_vine_cave_violet')
|
||||||
end
|
local c_everness_wall_vine_cave_blue = minetest.get_content_id('everness:wall_vine_cave_blue')
|
||||||
|
local c_everness_mineral_lava_stone = minetest.get_content_id('everness:mineral_lava_stone')
|
||||||
local dirs = {
|
local c_everness_mineral_cave_stone = minetest.get_content_id('everness:mineral_cave_stone')
|
||||||
{ x = 1, z = 0 },
|
local c_everness_lava_source = minetest.get_content_id('everness:lava_source')
|
||||||
{ x = -1, z = 0 },
|
local c_everness_marker = minetest.get_content_id('everness:marker')
|
||||||
{ x = 0, z = 1 },
|
local c_everness_volcanic_rock = minetest.get_content_id('everness:volcanic_rock')
|
||||||
{ x = 0, z = -1 }
|
local c_everness_volcanic_spike_1 = minetest.get_content_id('everness:volcanic_spike_1')
|
||||||
}
|
local c_everness_volcanic_spike_2 = minetest.get_content_id('everness:volcanic_spike_2')
|
||||||
|
local c_everness_volcanic_spike_3 = minetest.get_content_id('everness:volcanic_spike_3')
|
||||||
local ret = {}
|
local c_everness_volcanic_spike_4 = minetest.get_content_id('everness:volcanic_spike_4')
|
||||||
local mindist = { x = 0, z = 0 }
|
local c_everness_volcanic_spike_5 = minetest.get_content_id('everness:volcanic_spike_5')
|
||||||
local min = function(a, b)
|
local c_everness_volcanic_spike_6 = minetest.get_content_id('everness:volcanic_spike_6')
|
||||||
return a ~= 0 and math.min(a, b) or b
|
local c_everness_volcanic_spike_7 = minetest.get_content_id('everness:volcanic_spike_7')
|
||||||
end
|
local c_everness_mineral_cave_stone_spike_1 = minetest.get_content_id('everness:mineral_cave_stone_spike_1')
|
||||||
|
local c_everness_mineral_cave_stone_spike_2 = minetest.get_content_id('everness:mineral_cave_stone_spike_2')
|
||||||
for _, dir in ipairs(dirs) do
|
local c_everness_mineral_cave_stone_spike_3 = minetest.get_content_id('everness:mineral_cave_stone_spike_3')
|
||||||
for i = 1, 9 do -- 9 = max room size / 2
|
local c_everness_mineral_cave_stone_spike_4 = minetest.get_content_id('everness:mineral_cave_stone_spike_4')
|
||||||
local pos = vector.add(cpos, {x=dir.x*i, y=0, z=dir.z*i})
|
local c_everness_mineral_cave_stone_spike_5 = minetest.get_content_id('everness:mineral_cave_stone_spike_5')
|
||||||
|
local c_everness_mineral_cave_stone_spike_6 = minetest.get_content_id('everness:mineral_cave_stone_spike_6')
|
||||||
-- continue in that direction until we find a wall-like node
|
local c_everness_mineral_cave_stone_spike_7 = minetest.get_content_id('everness:mineral_cave_stone_spike_7')
|
||||||
local node = minetest.get_node(pos)
|
-- Biome IDs
|
||||||
if is_wall(node) then
|
|
||||||
local front_below = vector.subtract(pos, {x=dir.x, y=1, z=dir.z})
|
|
||||||
local above = vector.add(pos, {x=0, y=1, z=0})
|
|
||||||
|
|
||||||
-- check that it:
|
|
||||||
--- is at least 2 nodes high (not a staircase)
|
|
||||||
--- has a floor
|
|
||||||
if is_wall(minetest.get_node(front_below)) and is_wall(minetest.get_node(above)) then
|
|
||||||
table.insert(ret, {pos = pos, facing = {x=-dir.x, y=0, z=-dir.z}})
|
|
||||||
if dir.z == 0 then
|
|
||||||
mindist.x = min(mindist.x, i-1)
|
|
||||||
else
|
|
||||||
mindist.z = min(mindist.z, i-1)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
-- abort even if it wasn't a wall cause something is in the way
|
|
||||||
break
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
return {
|
|
||||||
walls = ret,
|
|
||||||
size = { x = mindist.x * 2, z = mindist.z * 2 }
|
|
||||||
}
|
|
||||||
end
|
|
||||||
|
|
||||||
local c_everness_pyrite_lantern = minetest.get_content_id('everness:pyrite_lantern')
|
|
||||||
local c_everness_cursed_pumpkin_lantern = minetest.get_content_id('everness:cursed_pumpkin_lantern')
|
|
||||||
local c_mapgen_stone = minetest.get_content_id('mapgen_stone')
|
|
||||||
local biome_id_everness_mineral_waters_under = minetest.get_biome_id('everness:mineral_waters_under')
|
local biome_id_everness_mineral_waters_under = minetest.get_biome_id('everness:mineral_waters_under')
|
||||||
|
-- Decoration IDs
|
||||||
|
local d_everness_mineral_waters_under_volcanic_spike = minetest.get_decoration_id('everness:mineral_waters_under_volcanic_spike')
|
||||||
|
local d_everness_mineral_waters_under_lava_stone_spike = minetest.get_decoration_id('everness:mineral_waters_under_lava_stone_spike')
|
||||||
|
|
||||||
-- minetest.set_gen_notify({
|
local volcanic_spike_place_on = minetest.registered_decorations['everness:mineral_waters_under_volcanic_spike'].place_on
|
||||||
-- large_cave_begin = true,
|
volcanic_spike_place_on = type(volcanic_spike_place_on) == 'string' and { volcanic_spike_place_on } or volcanic_spike_place_on
|
||||||
-- large_cave_end = true
|
local lava_stone_spike_place_on = minetest.registered_decorations['everness:mineral_waters_under_lava_stone_spike'].place_on
|
||||||
-- })
|
lava_stone_spike_place_on = type(lava_stone_spike_place_on) == 'string' and { lava_stone_spike_place_on } or lava_stone_spike_place_on
|
||||||
|
|
||||||
|
|
||||||
|
local wall_vines = {
|
||||||
|
c_everness_wall_vine_cave_cyan,
|
||||||
|
c_everness_wall_vine_cave_violet,
|
||||||
|
c_everness_wall_vine_cave_blue
|
||||||
|
}
|
||||||
|
|
||||||
|
local volcanic_spike_map = {
|
||||||
|
c_everness_volcanic_rock,
|
||||||
|
c_everness_volcanic_spike_1,
|
||||||
|
c_everness_volcanic_spike_2,
|
||||||
|
c_everness_volcanic_spike_3,
|
||||||
|
c_everness_volcanic_spike_4,
|
||||||
|
c_everness_volcanic_spike_5,
|
||||||
|
c_everness_volcanic_spike_6,
|
||||||
|
c_everness_volcanic_spike_7
|
||||||
|
}
|
||||||
|
|
||||||
|
local lava_stone_spike_map = {
|
||||||
|
c_everness_mineral_cave_stone,
|
||||||
|
c_everness_mineral_cave_stone_spike_1,
|
||||||
|
c_everness_mineral_cave_stone_spike_2,
|
||||||
|
c_everness_mineral_cave_stone_spike_3,
|
||||||
|
c_everness_mineral_cave_stone_spike_4,
|
||||||
|
c_everness_mineral_cave_stone_spike_5,
|
||||||
|
c_everness_mineral_cave_stone_spike_6,
|
||||||
|
c_everness_mineral_cave_stone_spike_7
|
||||||
|
}
|
||||||
|
|
||||||
|
minetest.set_gen_notify({ decoration = true }, {
|
||||||
|
d_everness_mineral_waters_under_volcanic_spike,
|
||||||
|
d_everness_mineral_waters_under_lava_stone_spike
|
||||||
|
})
|
||||||
|
|
||||||
Everness:add_to_queue_on_generated({
|
Everness:add_to_queue_on_generated({
|
||||||
name = 'everness:mineral_waters_under',
|
name = 'everness:mineral_waters_under',
|
||||||
|
@ -156,7 +246,100 @@ Everness:add_to_queue_on_generated({
|
||||||
-- read/write to `data` what will be eventually saved (set_data)
|
-- read/write to `data` what will be eventually saved (set_data)
|
||||||
-- used for voxelmanip `data` manipulation
|
-- used for voxelmanip `data` manipulation
|
||||||
on_data = function(minp, maxp, area, data, p2data, gennotify, rand, shared_args)
|
on_data = function(minp, maxp, area, data, p2data, gennotify, rand, shared_args)
|
||||||
|
--
|
||||||
|
-- Lakes
|
||||||
|
--
|
||||||
|
for z = minp.z, maxp.z do
|
||||||
|
for y = minp.y, maxp.y do
|
||||||
|
for x = minp.x, maxp.x do
|
||||||
|
local ai = area:index(x, y, z)
|
||||||
|
local c_current = data[ai]
|
||||||
|
|
||||||
|
-- +Y, -Y, +X, -X, +Z, -Z
|
||||||
|
-- top, bottom, right, left, front, back
|
||||||
|
-- right
|
||||||
|
local c_right = data[ai + 1]
|
||||||
|
-- left
|
||||||
|
local c_left = data[ai - 1]
|
||||||
|
-- front
|
||||||
|
local c_front = data[ai + area.zstride]
|
||||||
|
-- back
|
||||||
|
local c_back = data[ai - area.zstride]
|
||||||
|
|
||||||
|
local keep_going = true
|
||||||
|
local while_count = 1
|
||||||
|
local max_dig_depth = 11
|
||||||
|
|
||||||
|
if
|
||||||
|
c_current == c_everness_mineral_lava_stone
|
||||||
|
and (
|
||||||
|
c_right == c_everness_mineral_lava_stone
|
||||||
|
or c_right == c_everness_mineral_cave_stone
|
||||||
|
or c_right == c_everness_lava_source
|
||||||
|
)
|
||||||
|
and (
|
||||||
|
c_left == c_everness_mineral_lava_stone
|
||||||
|
or c_left == c_everness_mineral_cave_stone
|
||||||
|
or c_left == c_everness_lava_source
|
||||||
|
)
|
||||||
|
and (
|
||||||
|
c_front == c_everness_mineral_lava_stone
|
||||||
|
or c_front == c_everness_mineral_cave_stone
|
||||||
|
or c_front == c_everness_lava_source
|
||||||
|
)
|
||||||
|
and (
|
||||||
|
c_back == c_everness_mineral_lava_stone
|
||||||
|
or c_back == c_everness_mineral_cave_stone
|
||||||
|
or c_back == c_everness_lava_source
|
||||||
|
)
|
||||||
|
then
|
||||||
|
-- dig below
|
||||||
|
while keep_going and while_count <= max_dig_depth do
|
||||||
|
local while_index = ai - area.ystride * while_count
|
||||||
|
|
||||||
|
if
|
||||||
|
-- below
|
||||||
|
data[while_index] == c_everness_mineral_cave_stone
|
||||||
|
and (
|
||||||
|
-- right
|
||||||
|
data[while_index + 1 + area.ystride] == c_everness_mineral_lava_stone
|
||||||
|
or data[while_index + 1 + area.ystride] == c_everness_lava_source
|
||||||
|
or data[while_index + 1 + area.ystride] == c_everness_mineral_cave_stone
|
||||||
|
)
|
||||||
|
and (
|
||||||
|
-- left
|
||||||
|
data[while_index - 1 + area.ystride] == c_everness_mineral_lava_stone
|
||||||
|
or data[while_index - 1 + area.ystride] == c_everness_lava_source
|
||||||
|
or data[while_index - 1 + area.ystride] == c_everness_mineral_cave_stone
|
||||||
|
)
|
||||||
|
and (
|
||||||
|
-- front
|
||||||
|
data[while_index + area.zstride + area.ystride] == c_everness_mineral_lava_stone
|
||||||
|
or data[while_index + area.zstride + area.ystride] == c_everness_lava_source
|
||||||
|
or data[while_index + area.zstride + area.ystride] == c_everness_mineral_cave_stone
|
||||||
|
)
|
||||||
|
and (
|
||||||
|
-- back
|
||||||
|
data[while_index - area.zstride + area.ystride] == c_everness_mineral_lava_stone
|
||||||
|
or data[while_index - area.zstride + area.ystride] == c_everness_lava_source
|
||||||
|
or data[while_index - area.zstride + area.ystride] == c_everness_mineral_cave_stone
|
||||||
|
)
|
||||||
|
then
|
||||||
|
data[while_index + area.ystride] = c_everness_lava_source
|
||||||
|
else
|
||||||
|
keep_going = false
|
||||||
|
end
|
||||||
|
|
||||||
|
while_count = while_count + 1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Decorations
|
||||||
|
--
|
||||||
for y = minp.y, maxp.y do
|
for y = minp.y, maxp.y do
|
||||||
for z = minp.z, maxp.z do
|
for z = minp.z, maxp.z do
|
||||||
for x = minp.x, maxp.x do
|
for x = minp.x, maxp.x do
|
||||||
|
@ -165,47 +348,116 @@ Everness:add_to_queue_on_generated({
|
||||||
if
|
if
|
||||||
data[vi] == minetest.CONTENT_AIR
|
data[vi] == minetest.CONTENT_AIR
|
||||||
and (
|
and (
|
||||||
data[vi + 1] == c_mapgen_stone
|
data[vi + 1] == c_everness_mineral_cave_stone
|
||||||
or data[vi - 1] == c_mapgen_stone
|
or data[vi - 1] == c_everness_mineral_cave_stone
|
||||||
or data[vi + area.zstride] == c_mapgen_stone
|
or data[vi + area.zstride] == c_everness_mineral_cave_stone
|
||||||
or data[vi - area.zstride] == c_mapgen_stone
|
or data[vi - area.zstride] == c_everness_mineral_cave_stone
|
||||||
)
|
)
|
||||||
and rand:next(0, 100) == 75
|
and rand:next(0, 100) <= 25
|
||||||
then
|
then
|
||||||
local rand_c_node = rand:next(1, 2) == 1 and c_everness_pyrite_lantern or c_everness_cursed_pumpkin_lantern
|
-- Decorate Walls
|
||||||
data[vi] = rand_c_node
|
local dir = vector.zero()
|
||||||
|
|
||||||
|
if data[vi + 1] == c_everness_mineral_cave_stone then
|
||||||
|
dir.x = 1
|
||||||
|
end
|
||||||
|
|
||||||
|
if data[vi - 1] == c_everness_mineral_cave_stone then
|
||||||
|
dir.x = -1
|
||||||
|
end
|
||||||
|
|
||||||
|
if data[vi + area.zstride] == c_everness_mineral_cave_stone then
|
||||||
|
dir.z = 1
|
||||||
|
end
|
||||||
|
|
||||||
|
if data[vi - area.zstride] == c_everness_mineral_cave_stone then
|
||||||
|
dir.z = -1
|
||||||
|
end
|
||||||
|
|
||||||
|
local rand_wall_vine = wall_vines[rand:next(1, #wall_vines)]
|
||||||
|
data[vi] = rand_wall_vine
|
||||||
|
p2data[vi] = minetest.dir_to_wallmounted(dir)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
-- for _, p in ipairs(gennotify['large_cave_end'] or {}) do
|
--
|
||||||
-- data[area:indexp(p)] = c_everness_cursed_pumpkin_lantern
|
-- Spikes
|
||||||
-- data[area:indexp(p)] = c_everness_cursed_pumpkin_lantern
|
--
|
||||||
|
for _, pos in ipairs(gennotify['decoration#' .. (d_everness_mineral_waters_under_volcanic_spike or '')] or {}) do
|
||||||
|
local idx = area:indexp(pos)
|
||||||
|
local idx_marker = idx + area.ystride
|
||||||
|
local place_on_node_name = minetest.get_name_from_content_id(data[idx])
|
||||||
|
|
||||||
-- local minpos = vector.subtract(p, { x = 9, y = 9, z = 9 })
|
if data[idx_marker] == c_everness_marker then
|
||||||
-- local maxpos = vector.add(p, { x = 9, y = 9, z = 9 })
|
-- remove marker
|
||||||
|
data[idx_marker] = minetest.CONTENT_AIR
|
||||||
|
|
||||||
-- for y = minpos.y, maxpos.y do
|
if table.indexof(volcanic_spike_place_on, place_on_node_name) ~= -1 then
|
||||||
-- for z = minpos.z, maxpos.z do
|
local min_height = 3
|
||||||
-- for x = minpos.x, maxpos.x do
|
local max_height = 8
|
||||||
-- local vi = area:index(x, y, z)
|
local indexes = Everness.find_content_in_vm_area(
|
||||||
|
vector.new(pos.x, pos.y + 1, pos.z),
|
||||||
|
vector.new(pos.x, pos.y + max_height, pos.z),
|
||||||
|
{
|
||||||
|
minetest.CONTENT_AIR
|
||||||
|
},
|
||||||
|
data,
|
||||||
|
area
|
||||||
|
)
|
||||||
|
|
||||||
-- if
|
-- For smallest spike we need space above at least 3)
|
||||||
-- data[vi] == minetest.CONTENT_AIR
|
if #indexes > min_height then
|
||||||
-- and (
|
local height = rand:next(min_height, #indexes)
|
||||||
-- data[vi + 1] == c_mapgen_stone
|
local start_index = #volcanic_spike_map - height + 1
|
||||||
-- or data[vi - 1] == c_mapgen_stone
|
local count = 0
|
||||||
-- or data[vi + area.zstride] == c_mapgen_stone
|
|
||||||
-- or data[vi - area.zstride] == c_mapgen_stone
|
for i = start_index, #volcanic_spike_map do
|
||||||
-- )
|
data[idx_marker + area.ystride * count] = volcanic_spike_map[i]
|
||||||
-- then
|
count = count + 1
|
||||||
-- data[vi] = minetest.get_content_id('default:apple')
|
end
|
||||||
-- end
|
end
|
||||||
-- end
|
end
|
||||||
-- end
|
end
|
||||||
-- end
|
end
|
||||||
-- end
|
|
||||||
|
for _, pos in ipairs(gennotify['decoration#' .. (d_everness_mineral_waters_under_lava_stone_spike or '')] or {}) do
|
||||||
|
local idx = area:indexp(pos)
|
||||||
|
local idx_marker = idx + area.ystride
|
||||||
|
local place_on_node_name = minetest.get_name_from_content_id(data[idx])
|
||||||
|
|
||||||
|
if data[idx_marker] == c_everness_marker then
|
||||||
|
-- remove marker
|
||||||
|
data[idx_marker] = minetest.CONTENT_AIR
|
||||||
|
|
||||||
|
if table.indexof(lava_stone_spike_place_on, place_on_node_name) ~= -1 then
|
||||||
|
local min_height = 3
|
||||||
|
local max_height = 8
|
||||||
|
local indexes = Everness.find_content_in_vm_area(
|
||||||
|
vector.new(pos.x, pos.y + 1, pos.z),
|
||||||
|
vector.new(pos.x, pos.y + max_height, pos.z),
|
||||||
|
{
|
||||||
|
minetest.CONTENT_AIR
|
||||||
|
},
|
||||||
|
data,
|
||||||
|
area
|
||||||
|
)
|
||||||
|
|
||||||
|
-- For smallest spike we need space above at least 3)
|
||||||
|
if #indexes > min_height then
|
||||||
|
local height = rand:next(min_height, #indexes)
|
||||||
|
local start_index = #lava_stone_spike_map - height + 1
|
||||||
|
local count = 0
|
||||||
|
|
||||||
|
for i = start_index, #lava_stone_spike_map do
|
||||||
|
data[idx_marker + area.ystride * count] = lava_stone_spike_map[i]
|
||||||
|
count = count + 1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
end,
|
end,
|
||||||
-- read-only (but cant and should not manipulate) voxelmanip `data`
|
-- read-only (but cant and should not manipulate) voxelmanip `data`
|
||||||
-- used for `place_schematic_on_vmanip` which will invalidate `data`
|
-- used for `place_schematic_on_vmanip` which will invalidate `data`
|
||||||
|
@ -216,6 +468,6 @@ Everness:add_to_queue_on_generated({
|
||||||
-- Used for direct manipulation of the world chunk nodes where the
|
-- Used for direct manipulation of the world chunk nodes where the
|
||||||
-- definitions of nodes are available and node callback can be executed
|
-- definitions of nodes are available and node callback can be executed
|
||||||
-- or e.g. for `minetest.fix_light`
|
-- or e.g. for `minetest.fix_light`
|
||||||
after_write_to_map = function(shared_args, gennotify)
|
after_write_to_map = function(shared_args, gennotify, rand)
|
||||||
end
|
end
|
||||||
})
|
})
|
||||||
|
|
|
@ -0,0 +1,109 @@
|
||||||
|
# Blender v2.83.20 OBJ File: 'everness_better_vine_1.blend'
|
||||||
|
# www.blender.org
|
||||||
|
mtllib everness_vine_wall.mtl
|
||||||
|
o Plane
|
||||||
|
v 0.470000 -0.490000 -0.470000
|
||||||
|
v -0.470000 -0.490000 -0.470000
|
||||||
|
v 0.470000 -0.490000 0.470000
|
||||||
|
v -0.470000 -0.490000 0.470000
|
||||||
|
v -0.752156 -0.490000 0.461451
|
||||||
|
v 0.751842 -0.492615 0.461221
|
||||||
|
v -0.751842 -0.272978 0.044555
|
||||||
|
v 0.752156 -0.275593 0.044326
|
||||||
|
v 0.752156 -0.275593 -0.073174
|
||||||
|
v -0.751842 -0.272978 -0.072945
|
||||||
|
v 0.751842 -0.492615 0.343721
|
||||||
|
v -0.752156 -0.490000 0.343951
|
||||||
|
v -0.752156 -0.490000 0.226451
|
||||||
|
v 0.751842 -0.492615 0.226221
|
||||||
|
v -0.751842 -0.272978 -0.190445
|
||||||
|
v 0.752156 -0.275593 -0.190674
|
||||||
|
v 0.752156 -0.275593 -0.308174
|
||||||
|
v -0.751842 -0.272978 -0.307945
|
||||||
|
v 0.751842 -0.492615 0.108721
|
||||||
|
v -0.752156 -0.490000 0.108951
|
||||||
|
v -0.752156 -0.490000 -0.008549
|
||||||
|
v 0.751842 -0.492615 -0.008779
|
||||||
|
v -0.751842 -0.272978 -0.425445
|
||||||
|
v 0.752156 -0.275593 -0.425674
|
||||||
|
v 0.752156 -0.275593 -0.543174
|
||||||
|
v -0.751842 -0.272978 -0.542945
|
||||||
|
v 0.751842 -0.492615 -0.126279
|
||||||
|
v -0.752156 -0.490000 -0.126049
|
||||||
|
v -0.752156 -0.490000 -0.243549
|
||||||
|
v 0.751842 -0.492615 -0.243779
|
||||||
|
v -0.751842 -0.272978 -0.660445
|
||||||
|
v 0.752156 -0.275593 -0.660674
|
||||||
|
v 0.752156 -0.275593 -0.778174
|
||||||
|
v -0.751842 -0.272978 -0.777945
|
||||||
|
v 0.751842 -0.492615 -0.361279
|
||||||
|
v -0.752156 -0.490000 -0.361050
|
||||||
|
v 0.752149 -0.315254 -0.905760
|
||||||
|
v -0.751849 -0.312629 -0.905760
|
||||||
|
v 0.751848 -0.487510 -0.468464
|
||||||
|
v -0.752149 -0.484885 -0.468463
|
||||||
|
vt -0.000000 0.727273
|
||||||
|
vt 1.000000 0.818182
|
||||||
|
vt -0.000000 0.818182
|
||||||
|
vt 1.000000 0.636364
|
||||||
|
vt 0.000000 0.727273
|
||||||
|
vt 0.000000 0.636364
|
||||||
|
vt 1.000000 0.545455
|
||||||
|
vt 0.000000 0.636364
|
||||||
|
vt 0.000000 0.545455
|
||||||
|
vt 1.000000 0.454546
|
||||||
|
vt 0.000000 0.545455
|
||||||
|
vt 0.000000 0.454546
|
||||||
|
vt 0.000000 0.363636
|
||||||
|
vt 1.000000 0.454546
|
||||||
|
vt 0.000000 0.454546
|
||||||
|
vt 0.000000 0.272727
|
||||||
|
vt 1.000000 0.363636
|
||||||
|
vt 0.000000 0.363636
|
||||||
|
vt 1.000000 0.181818
|
||||||
|
vt 0.000000 0.272727
|
||||||
|
vt 0.000000 0.181818
|
||||||
|
vt 1.000000 0.090909
|
||||||
|
vt 0.000000 0.181818
|
||||||
|
vt 0.000000 0.090909
|
||||||
|
vt 0.000000 -0.000000
|
||||||
|
vt 1.000000 0.090909
|
||||||
|
vt 0.000000 0.090909
|
||||||
|
vt 0.166667 0.818182
|
||||||
|
vt 0.833333 1.000000
|
||||||
|
vt 0.833333 0.818182
|
||||||
|
vt 1.000000 0.727273
|
||||||
|
vt 1.000000 0.727273
|
||||||
|
vt 1.000000 0.636364
|
||||||
|
vt 1.000000 0.545455
|
||||||
|
vt 1.000000 0.363636
|
||||||
|
vt 1.000000 0.272727
|
||||||
|
vt 1.000000 0.272727
|
||||||
|
vt 1.000000 0.181818
|
||||||
|
vt 1.000000 0.000000
|
||||||
|
vt 0.166667 1.000000
|
||||||
|
vn 0.0016 0.8870 0.4617
|
||||||
|
vn 0.0016 0.9304 0.3665
|
||||||
|
vn 0.0000 1.0000 -0.0000
|
||||||
|
usemtl leaves
|
||||||
|
s off
|
||||||
|
f 8/1/1 5/2/1 6/3/1
|
||||||
|
f 10/4/1 11/5/1 9/6/1
|
||||||
|
f 15/7/1 14/8/1 16/9/1
|
||||||
|
f 18/10/1 19/11/1 17/12/1
|
||||||
|
f 24/13/1 21/14/1 22/15/1
|
||||||
|
f 25/16/1 28/17/1 27/18/1
|
||||||
|
f 31/19/1 30/20/1 32/21/1
|
||||||
|
f 34/22/1 35/23/1 33/24/1
|
||||||
|
f 37/25/2 40/26/2 39/27/2
|
||||||
|
f 3/28/3 2/29/3 4/30/3
|
||||||
|
f 8/1/1 7/31/1 5/2/1
|
||||||
|
f 10/4/1 12/32/1 11/5/1
|
||||||
|
f 15/7/1 13/33/1 14/8/1
|
||||||
|
f 18/10/1 20/34/1 19/11/1
|
||||||
|
f 24/13/1 23/35/1 21/14/1
|
||||||
|
f 25/16/1 26/36/1 28/17/1
|
||||||
|
f 31/19/1 29/37/1 30/20/1
|
||||||
|
f 34/22/1 36/38/1 35/23/1
|
||||||
|
f 37/25/2 38/39/2 40/26/2
|
||||||
|
f 3/28/3 1/40/3 2/29/3
|
117
nodes.lua
|
@ -2625,7 +2625,7 @@ Everness:register_node('everness:flame_permanent_blue', {
|
||||||
-- Mapgen Marker
|
-- Mapgen Marker
|
||||||
|
|
||||||
Everness:register_node('everness:marker', {
|
Everness:register_node('everness:marker', {
|
||||||
drawtype = 'airlike',
|
-- drawtype = 'airlike',
|
||||||
description = 'Marker for mapgen',
|
description = 'Marker for mapgen',
|
||||||
tiles = { 'everness_lootchest_marker_top.png', 'everness_lootchest_marker_side.png' },
|
tiles = { 'everness_lootchest_marker_top.png', 'everness_lootchest_marker_side.png' },
|
||||||
groups = { dig_immediate = 3, not_in_creative_inventory = 1 },
|
groups = { dig_immediate = 3, not_in_creative_inventory = 1 },
|
||||||
|
@ -11478,6 +11478,121 @@ Everness:register_node('everness:mineral_water_flowing', {
|
||||||
sounds = Everness.node_sound_water_defaults(),
|
sounds = Everness.node_sound_water_defaults(),
|
||||||
})
|
})
|
||||||
|
|
||||||
|
minetest.register_node('everness:lava_source', {
|
||||||
|
description = S('Lava Source'),
|
||||||
|
drawtype = 'liquid',
|
||||||
|
tiles = {
|
||||||
|
{
|
||||||
|
name = 'everness_lava_source_animated.png',
|
||||||
|
backface_culling = false,
|
||||||
|
animation = {
|
||||||
|
type = 'vertical_frames',
|
||||||
|
aspect_w = 16,
|
||||||
|
aspect_h = 16,
|
||||||
|
length = 6,
|
||||||
|
},
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name = 'everness_lava_source_animated.png',
|
||||||
|
backface_culling = true,
|
||||||
|
animation = {
|
||||||
|
type = 'vertical_frames',
|
||||||
|
aspect_w = 16,
|
||||||
|
aspect_h = 16,
|
||||||
|
length = 6,
|
||||||
|
},
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
},
|
||||||
|
},
|
||||||
|
paramtype = 'light',
|
||||||
|
light_source = 13,
|
||||||
|
walkable = false,
|
||||||
|
pointable = false,
|
||||||
|
diggable = false,
|
||||||
|
buildable_to = true,
|
||||||
|
is_ground_content = false,
|
||||||
|
drop = '',
|
||||||
|
drowning = 1,
|
||||||
|
liquidtype = 'source',
|
||||||
|
liquid_alternative_flowing = 'everness:lava_flowing',
|
||||||
|
liquid_alternative_source = 'everness:lava_source',
|
||||||
|
liquid_viscosity = 7,
|
||||||
|
liquid_renewable = false,
|
||||||
|
damage_per_second = 4 * 2,
|
||||||
|
post_effect_color = { a = 191, r = 255, g = 64, b = 0 },
|
||||||
|
groups = {
|
||||||
|
lava = 3,
|
||||||
|
liquid = 2,
|
||||||
|
igniter = 1
|
||||||
|
},
|
||||||
|
liquid_range = 2,
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node('everness:lava_flowing', {
|
||||||
|
description = S('Flowing Lava'),
|
||||||
|
drawtype = 'flowingliquid',
|
||||||
|
tiles = {
|
||||||
|
{
|
||||||
|
name = 'everness_lava_source_animated.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
}
|
||||||
|
},
|
||||||
|
special_tiles = {
|
||||||
|
{
|
||||||
|
name = 'everness_lava_flowing_animated.png',
|
||||||
|
backface_culling = false,
|
||||||
|
animation = {
|
||||||
|
type = 'vertical_frames',
|
||||||
|
aspect_w = 16,
|
||||||
|
aspect_h = 16,
|
||||||
|
length = 3.3,
|
||||||
|
},
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name = 'everness_lava_flowing_animated.png',
|
||||||
|
backface_culling = true,
|
||||||
|
animation = {
|
||||||
|
type = 'vertical_frames',
|
||||||
|
aspect_w = 16,
|
||||||
|
aspect_h = 16,
|
||||||
|
length = 3.3,
|
||||||
|
},
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
},
|
||||||
|
},
|
||||||
|
paramtype = 'light',
|
||||||
|
paramtype2 = 'flowingliquid',
|
||||||
|
light_source = 13,
|
||||||
|
walkable = false,
|
||||||
|
pointable = false,
|
||||||
|
diggable = false,
|
||||||
|
buildable_to = true,
|
||||||
|
is_ground_content = false,
|
||||||
|
drop = '',
|
||||||
|
drowning = 1,
|
||||||
|
liquidtype = 'flowing',
|
||||||
|
liquid_alternative_flowing = 'everness:lava_flowing',
|
||||||
|
liquid_alternative_source = 'everness:lava_source',
|
||||||
|
liquid_viscosity = 7,
|
||||||
|
liquid_renewable = false,
|
||||||
|
damage_per_second = 4 * 2,
|
||||||
|
post_effect_color = { a = 191, r = 255, g = 64, b = 0 },
|
||||||
|
groups = {
|
||||||
|
lava = 3,
|
||||||
|
liquid = 2,
|
||||||
|
igniter = 1,
|
||||||
|
not_in_creative_inventory = 1
|
||||||
|
},
|
||||||
|
liquid_range = 2,
|
||||||
|
})
|
||||||
|
|
||||||
Everness:register_node('everness:water_geyser', {
|
Everness:register_node('everness:water_geyser', {
|
||||||
description = S('Water') .. ' ' .. S('Geyser'),
|
description = S('Water') .. ' ' .. S('Geyser'),
|
||||||
drawtype = 'mesh',
|
drawtype = 'mesh',
|
||||||
|
|
|
@ -16,17 +16,86 @@
|
||||||
|
|
||||||
local S = minetest.get_translator(minetest.get_current_modname())
|
local S = minetest.get_translator(minetest.get_current_modname())
|
||||||
|
|
||||||
Everness:register_node('everness:mineral_lava_stone', {
|
Everness:register_node('everness:mineral_cave_stone', {
|
||||||
description = S('Mineral Lava Stone'),
|
description = S('Mineral Cave Stone'),
|
||||||
-- Textures of node; +Y, -Y, +X, -X, +Z, -Z
|
|
||||||
tiles = {
|
tiles = {
|
||||||
{
|
{
|
||||||
name = 'everness_mineral_lava_stone.png',
|
name = 'everness_mineral_stone_under_top.png',
|
||||||
align_style = 'world',
|
align_style = 'world',
|
||||||
scale = 2
|
scale = 2
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name = 'everness_mineral_lava_stone.png',
|
name = 'everness_mineral_stone_under_top.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_stone_under.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
}
|
||||||
|
},
|
||||||
|
drop = 'everness:mineral_cave_cobblestone',
|
||||||
|
groups = {
|
||||||
|
-- MTG
|
||||||
|
cracky = 3,
|
||||||
|
-- MCL
|
||||||
|
pickaxey = 1,
|
||||||
|
building_block = 1,
|
||||||
|
material_stone = 1,
|
||||||
|
-- ALL
|
||||||
|
stone = 1,
|
||||||
|
},
|
||||||
|
_mcl_blast_resistance = 6,
|
||||||
|
_mcl_hardness = 1.5,
|
||||||
|
_mcl_silk_touch_drop = true,
|
||||||
|
sounds = Everness.node_sound_stone_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
Everness:register_node('everness:mineral_cave_cobblestone', {
|
||||||
|
description = S('Mineral Cave Cobblestone'),
|
||||||
|
is_ground_content = false,
|
||||||
|
tiles = {
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_cobblestone_under.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
}
|
||||||
|
},
|
||||||
|
groups = {
|
||||||
|
-- MTG
|
||||||
|
cracky = 3,
|
||||||
|
-- MCL
|
||||||
|
pickaxey = 1,
|
||||||
|
building_block = 1,
|
||||||
|
material_stone = 1,
|
||||||
|
-- ALL
|
||||||
|
stone = 2,
|
||||||
|
},
|
||||||
|
_mcl_blast_resistance = 6,
|
||||||
|
_mcl_hardness = 1.5,
|
||||||
|
_mcl_silk_touch_drop = true,
|
||||||
|
sounds = Everness.node_sound_stone_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
Everness:register_node('everness:mineral_lava_stone', {
|
||||||
|
description = S('Mineral Lava Stone with lava'),
|
||||||
|
is_ground_content = false,
|
||||||
|
-- Textures of node; +Y, -Y, +X, -X, +Z, -Z
|
||||||
|
tiles = {
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_lava_stone_animated.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2,
|
||||||
|
animation = {
|
||||||
|
type = 'vertical_frames',
|
||||||
|
aspect_w = 16,
|
||||||
|
aspect_h = 16,
|
||||||
|
length = 6.4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_lava_stone_bottom.png',
|
||||||
align_style = 'world',
|
align_style = 'world',
|
||||||
scale = 2
|
scale = 2
|
||||||
},
|
},
|
||||||
|
@ -36,7 +105,7 @@ Everness:register_node('everness:mineral_lava_stone', {
|
||||||
scale = 2
|
scale = 2
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
-- drop = 'everness:coral_desert_cobble',
|
drop = 'everness:mineral_lava_stone_dry',
|
||||||
groups = {
|
groups = {
|
||||||
-- MTG
|
-- MTG
|
||||||
cracky = 3,
|
cracky = 3,
|
||||||
|
@ -53,3 +122,162 @@ Everness:register_node('everness:mineral_lava_stone', {
|
||||||
light_source = 3,
|
light_source = 3,
|
||||||
sounds = Everness.node_sound_stone_defaults(),
|
sounds = Everness.node_sound_stone_defaults(),
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Everness:register_node('everness:mineral_lava_stone_dry', {
|
||||||
|
description = S('Mineral Lava Stone without lava'),
|
||||||
|
is_ground_content = false,
|
||||||
|
-- Textures of node; +Y, -Y, +X, -X, +Z, -Z
|
||||||
|
tiles = {
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_lava_stone_bottom.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
}
|
||||||
|
},
|
||||||
|
groups = {
|
||||||
|
-- MTG
|
||||||
|
cracky = 3,
|
||||||
|
-- MCL
|
||||||
|
pickaxey = 1,
|
||||||
|
building_block = 1,
|
||||||
|
material_stone = 1,
|
||||||
|
-- ALL
|
||||||
|
stone = 1,
|
||||||
|
},
|
||||||
|
_mcl_blast_resistance = 6,
|
||||||
|
_mcl_hardness = 1.5,
|
||||||
|
_mcl_silk_touch_drop = true,
|
||||||
|
sounds = Everness.node_sound_stone_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
for i = 1, 7 do
|
||||||
|
Everness:register_node('everness:volcanic_spike_' .. i, {
|
||||||
|
description = S('Volcanic Spike') .. ' ' .. i,
|
||||||
|
tiles = { 'everness_volcanic_rock.png' },
|
||||||
|
sounds = Everness.node_sound_stone_defaults(),
|
||||||
|
drawtype = 'nodebox',
|
||||||
|
groups = {
|
||||||
|
-- MTG
|
||||||
|
cracky = 1,
|
||||||
|
level = 2,
|
||||||
|
stone = 1,
|
||||||
|
-- MCL
|
||||||
|
pickaxey = 5,
|
||||||
|
building_block = 1,
|
||||||
|
material_stone = 1
|
||||||
|
},
|
||||||
|
_mcl_blast_resistance = 1200,
|
||||||
|
_mcl_hardness = 50,
|
||||||
|
is_ground_content = false,
|
||||||
|
node_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
{
|
||||||
|
(-8 + i) / 16,
|
||||||
|
-8 / 16,
|
||||||
|
(-8 + i) / 16,
|
||||||
|
(8 - i) / 16,
|
||||||
|
8 / 16,
|
||||||
|
(8 - i) / 16
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
selection_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
(-8 + i - 1) / 16,
|
||||||
|
-8 / 16,
|
||||||
|
(-8 + i - 1) / 16,
|
||||||
|
(8 - i + 1) / 16,
|
||||||
|
8 / 16,
|
||||||
|
(8 - i + 1) / 16
|
||||||
|
}
|
||||||
|
},
|
||||||
|
collision_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
(-8 + i) / 16,
|
||||||
|
-8 / 16,
|
||||||
|
(-8 + i) / 16,
|
||||||
|
(8 - i) / 16,
|
||||||
|
8 / 16,
|
||||||
|
(8 - i) / 16
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
|
for i = 1, 7 do
|
||||||
|
Everness:register_node('everness:mineral_cave_stone_spike_' .. i, {
|
||||||
|
description = S('Mineral Lava Stone Spike') .. ' ' .. i,
|
||||||
|
-- Textures of node; +Y, -Y, +X, -X, +Z, -Z
|
||||||
|
tiles = {
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_stone_under_top.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_stone_under_top.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name = 'everness_mineral_stone_under.png',
|
||||||
|
align_style = 'world',
|
||||||
|
scale = 2
|
||||||
|
}
|
||||||
|
},
|
||||||
|
groups = {
|
||||||
|
-- MTG
|
||||||
|
cracky = 3,
|
||||||
|
-- MCL
|
||||||
|
pickaxey = 1,
|
||||||
|
building_block = 1,
|
||||||
|
material_stone = 1,
|
||||||
|
-- ALL
|
||||||
|
stone = 1,
|
||||||
|
},
|
||||||
|
_mcl_blast_resistance = 6,
|
||||||
|
_mcl_hardness = 1.5,
|
||||||
|
_mcl_silk_touch_drop = true,
|
||||||
|
sounds = Everness.node_sound_stone_defaults(),
|
||||||
|
drawtype = 'nodebox',
|
||||||
|
is_ground_content = false,
|
||||||
|
node_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
{
|
||||||
|
(-8 + i) / 16,
|
||||||
|
-8 / 16,
|
||||||
|
(-8 + i) / 16,
|
||||||
|
(8 - i) / 16,
|
||||||
|
8 / 16,
|
||||||
|
(8 - i) / 16
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
selection_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
(-8 + i - 1) / 16,
|
||||||
|
-8 / 16,
|
||||||
|
(-8 + i - 1) / 16,
|
||||||
|
(8 - i + 1) / 16,
|
||||||
|
8 / 16,
|
||||||
|
(8 - i + 1) / 16
|
||||||
|
}
|
||||||
|
},
|
||||||
|
collision_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
(-8 + i) / 16,
|
||||||
|
-8 / 16,
|
||||||
|
(-8 + i) / 16,
|
||||||
|
(8 - i) / 16,
|
||||||
|
8 / 16,
|
||||||
|
(8 - i) / 16
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
15
skybox.lua
|
@ -729,6 +729,21 @@ local skybox_defs = {
|
||||||
scale = 0.5
|
scale = 0.5
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
['everness:mineral_waters_under'] = {
|
||||||
|
sky_parameters = {
|
||||||
|
type = 'regular',
|
||||||
|
sky_color = {
|
||||||
|
day_sky = '#8B1408',
|
||||||
|
day_horizon = '#b2380a',
|
||||||
|
dawn_sky = '#8B1408',
|
||||||
|
dawn_horizon = '#b2380a',
|
||||||
|
night_sky = '#A3609E',
|
||||||
|
night_horizon = '#C7A8D9',
|
||||||
|
fog_sun_tint = '#8B1408',
|
||||||
|
fog_moon_tint = '#520E49'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
local function should_flip(player)
|
local function should_flip(player)
|
||||||
|
|
After Width: | Height: | Size: 12 KiB |
After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 2.5 KiB |
After Width: | Height: | Size: 11 KiB |
After Width: | Height: | Size: 635 B |
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.6 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 2.0 KiB |
|
@ -0,0 +1,111 @@
|
||||||
|
--[[
|
||||||
|
Everness. Never ending discovery in Everness mapgen.
|
||||||
|
Copyright (C) 2024 SaKeL
|
||||||
|
|
||||||
|
This library is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU Lesser General Public
|
||||||
|
License as published by the Free Software Foundation; either
|
||||||
|
version 2.1 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This library is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
Lesser General Public License for more details.
|
||||||
|
|
||||||
|
--]]
|
||||||
|
|
||||||
|
local S = minetest.get_translator(minetest.get_current_modname())
|
||||||
|
|
||||||
|
local function register_vine_wall(name, def, overrides)
|
||||||
|
local _def = table.copy(def)
|
||||||
|
local _name = name
|
||||||
|
|
||||||
|
_def.short_description = _def.short_description or _def.description
|
||||||
|
_def.drawtype = 'mesh'
|
||||||
|
_def.tiles = _def.tiles or {
|
||||||
|
{ name = 'everness_' .. _name .. '.png' }
|
||||||
|
}
|
||||||
|
_def.mesh = 'everness_vine_wall.obj'
|
||||||
|
_def.use_texture_alpha = 'clip'
|
||||||
|
_def.paramtype = 'light'
|
||||||
|
_def.paramtype2 = 'wallmounted'
|
||||||
|
_def.sunlight_propagates = true
|
||||||
|
_def.walkable = false
|
||||||
|
_def.climbable = true
|
||||||
|
_def.buildable_to = false
|
||||||
|
_def.sounds = Everness.node_sound_leaves_defaults()
|
||||||
|
_def.groups = {
|
||||||
|
-- MTG
|
||||||
|
vine = 1,
|
||||||
|
snappy = 3,
|
||||||
|
-- Everness
|
||||||
|
falling_vines = 1,
|
||||||
|
no_silktouch = 1,
|
||||||
|
-- X Farming
|
||||||
|
compost = 30,
|
||||||
|
-- MCL
|
||||||
|
handy = 1,
|
||||||
|
axey = 1,
|
||||||
|
shearsy = 1,
|
||||||
|
swordy = 1,
|
||||||
|
deco_block = 1,
|
||||||
|
dig_by_piston = 1,
|
||||||
|
destroy_by_lava_flow = 1,
|
||||||
|
compostability = 30,
|
||||||
|
fire_encouragement = 15,
|
||||||
|
fire_flammability = 100,
|
||||||
|
-- ALL
|
||||||
|
flammable = 2,
|
||||||
|
attached_node = 1,
|
||||||
|
}
|
||||||
|
_def._mcl_blast_resistance = 0.2
|
||||||
|
_def._mcl_hardness = 0.2
|
||||||
|
_def.selection_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
-8 / 16,
|
||||||
|
-8 / 16,
|
||||||
|
-8 / 16,
|
||||||
|
8 / 16,
|
||||||
|
-5 / 16,
|
||||||
|
8 / 16
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_def.collision_box = {
|
||||||
|
type = 'fixed',
|
||||||
|
fixed = {
|
||||||
|
-8 / 16,
|
||||||
|
-8 / 16,
|
||||||
|
-8 / 16,
|
||||||
|
8 / 16,
|
||||||
|
-5 / 16,
|
||||||
|
8 / 16
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_def.waving = 3
|
||||||
|
_def.light_source = _def.light_source or 4
|
||||||
|
|
||||||
|
_def.on_rotate = function()
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
|
||||||
|
Everness:register_node('everness:' .. _name, _def)
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Cave vine
|
||||||
|
|
||||||
|
register_vine_wall('wall_vine_cave_green', {
|
||||||
|
description = S('Wall Cave Vine Green'),
|
||||||
|
})
|
||||||
|
|
||||||
|
register_vine_wall('wall_vine_cave_blue', {
|
||||||
|
description = S('Wall Cave Vine Blue'),
|
||||||
|
})
|
||||||
|
|
||||||
|
register_vine_wall('wall_vine_cave_cyan', {
|
||||||
|
description = S('Wall Cave Vine Cyan'),
|
||||||
|
})
|
||||||
|
|
||||||
|
register_vine_wall('wall_vine_cave_violet', {
|
||||||
|
description = S('Wall Cave Vine Violet'),
|
||||||
|
})
|