add missing cold_star node and timer function
This commit is contained in:
parent
2fe08e41eb
commit
74440f12cb
@ -9,9 +9,9 @@ local function nssm_register_noneatcraftitems (name, descr)
|
||||
})
|
||||
end
|
||||
|
||||
nssm_register_noneatcraftitems ("masticone_core","Masticone Core")
|
||||
nssm_register_noneatcraftitems ("berinhog_horn","Berinhog Horn")
|
||||
nssm_register_noneatcraftitems ("earth_heart","Earth Heart")
|
||||
nssm_register_noneatcraftitems ("masticone_core", "Masticone Core")
|
||||
nssm_register_noneatcraftitems ("berinhog_horn", "Berinhog Horn")
|
||||
nssm_register_noneatcraftitems ("earth_heart", "Earth Heart")
|
||||
|
||||
|
||||
minetest.register_craftitem(":nssm:cold_stars", {
|
||||
@ -28,10 +28,11 @@ minetest.register_craftitem(":nssm:cold_stars", {
|
||||
local dz = math.random(-20, 20)
|
||||
local pos1 = {x = pos1.x + dx, y = pos1.y + dy, z = pos1.z + dz}
|
||||
|
||||
if not minetest.is_protected(pos, "")
|
||||
or not minetest.get_item_group(minetest.get_node(pos).name, "unbreakable") == 1 then
|
||||
minetest.set_node(pos1, {name = "nssm:cold_star"})
|
||||
minetest.get_node_timer(pos1):start(400)
|
||||
if not minetest.is_protected(pos1, "")
|
||||
or not minetest.get_item_group(
|
||||
minetest.get_node(pos1).name, "unbreakable") == 1 then
|
||||
|
||||
minetest.set_node(pos1, {name="nssm:cold_star"})
|
||||
end
|
||||
end
|
||||
|
||||
@ -45,12 +46,34 @@ minetest.register_craftitem(":nssm:cold_stars", {
|
||||
|
||||
-- nodes
|
||||
|
||||
minetest.register_node(":nssm:cold_star", {
|
||||
drawtype = "plantlike",
|
||||
tiles = {"cold_star.png"},
|
||||
light_source = 13,
|
||||
walkable = false,
|
||||
paramtype = "light",
|
||||
pointable = false,
|
||||
buildable_to = true,
|
||||
sunlight_propagates = true,
|
||||
groups = {not_in_creative_inventory = 1},
|
||||
drop = {},
|
||||
|
||||
on_construct = function(pos)
|
||||
minetest.get_node_timer(pos):start(400)
|
||||
end,
|
||||
|
||||
on_timer = function(pos)
|
||||
minetest.remove_node(pos)
|
||||
end,
|
||||
|
||||
on_blast = function() end,
|
||||
})
|
||||
|
||||
minetest.register_node(":nssm:crystal_gas", {
|
||||
description = "Crystal Gas",
|
||||
drawtype = "airlike",
|
||||
paramtype = "light",
|
||||
walkable = false,
|
||||
-- sunlight_propagates = true,
|
||||
pointable = false,
|
||||
diggable = false,
|
||||
buildable_to = true,
|
||||
@ -89,8 +112,8 @@ minetest.register_node(":nssm:mud", {
|
||||
inventory_image = "mude.png",
|
||||
tiles = {
|
||||
{
|
||||
name="mud_animated.png",
|
||||
animation={
|
||||
name = "mud_animated.png",
|
||||
animation = {
|
||||
type = "vertical_frames", aspect_w = 16, aspect_h = 16, length = 16.0
|
||||
}
|
||||
}
|
||||
@ -103,7 +126,7 @@ minetest.register_node(":nssm:mud", {
|
||||
drowning = 0,
|
||||
liquid_renewable = false,
|
||||
liquidtype = "source",
|
||||
liquid_range= 0,
|
||||
liquid_range = 0,
|
||||
liquid_alternative_flowing = "nssm:mud",
|
||||
liquid_alternative_source = "nssm:mud",
|
||||
liquid_viscosity = 10,
|
||||
@ -162,7 +185,7 @@ local function nssm_register_egg(name, descr)
|
||||
|
||||
local pos1 = minetest.get_pointed_thing_position(pointed_thing, true)
|
||||
|
||||
pos1.y=pos1.y + 1.5
|
||||
pos1.y = pos1.y + 1.5
|
||||
|
||||
core.after(0.1, function()
|
||||
minetest.add_entity(pos1, "nssm:" .. name)
|
||||
@ -216,4 +239,3 @@ nssm_register_egg("pumpkid", "Pumpkid")
|
||||
nssm_register_egg("salamander", "Salamander")
|
||||
nssm_register_egg("flust", "Flust")
|
||||
nssm_register_egg("pelagia", "Pelagia")
|
||||
|
||||
|
BIN
textures/cold_star.png
Normal file
BIN
textures/cold_star.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 798 B |
Loading…
x
Reference in New Issue
Block a user