Compare commits

...

5 Commits

Author SHA1 Message Date
Elias Fleckenstein 6ea5331268 Fishes drown in air 2020-06-02 17:42:17 +02:00
Elias Fleckenstein 653d2a38e6 Fishes drown in air 2020-06-02 17:41:35 +02:00
Elias Fleckenstein 7732a5b8db Bugfix 2020-06-02 16:03:24 +02:00
EliasFleckenstein03 6bd8e75c61
Update init.lua 2020-06-02 15:55:37 +02:00
EliasFleckenstein03 fc0349c916
Update init.lua
Give coral skeleton back its original shape
2020-05-07 19:33:43 +02:00
1 changed files with 29 additions and 10 deletions

View File

@ -782,12 +782,6 @@ minetest.register_node("xocean:horn", {
minetest.set_node(pos, {name = "default:coral_brown"})
end,
})
minetest.override_item("default:coral_skeleton", {
description = "Horn Coral Skeleton Block",
tiles = {"xocean_coral_horn_skeleton.png"},
groups = {cracky = 3},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("xocean:skeleton_horn", {
description = "Horn Coral Skeleton",
drawtype = "plantlike_rooted",
@ -804,8 +798,8 @@ minetest.register_node("xocean:skeleton_horn", {
{-4/16, 0.5, -4/16, 4/16, 1.5, 4/16},
},
},
drop = "xocean:skeleton:horn",
node_dig_prediction = "xocean:horn_skeleton",
drop = "xocean:skeleton_horn",
node_dig_prediction = "xocean:skeleton_horn",
node_placement_prediction = "",
sounds = default.node_sound_stone_defaults({
dig = {name = "default_dig_snappy", gain = 0.2},
@ -821,7 +815,7 @@ minetest.register_node("xocean:skeleton_horn", {
local pos_under = pointed_thing.under
local pos_above = pointed_thing.above
if minetest.get_node(pos_under).name ~= "xocean:horn_skeleton" or
if minetest.get_node(pos_under).name ~= "xocean:skeleton_horn" or
minetest.get_node(pos_above).name ~= "default:water_source" then
return itemstack
end
@ -842,7 +836,7 @@ minetest.register_node("xocean:skeleton_horn", {
end,
after_destruct = function(pos, oldnode)
minetest.set_node(pos, {name = "xocean:horn_skeleton"})
minetest.set_node(pos, {name = "xocean:skeleton_horn"})
end,
})
minetest.override_item("default:coral_orange", {
@ -1743,6 +1737,7 @@ mobs:register_mob("xocean:fish", {
water_damage = 0,
lava_damage = 10,
light_damage = 0,
air_damage = 2,
animation = {
speed_normal = 15,
speed_run = 25,
@ -1753,6 +1748,12 @@ mobs:register_mob("xocean:fish", {
run_start = 40,
run_end = 100,
},
do_custom = function(self, dtime)
if self.standing_in == "air" then
self.health = self.health - dtime
self:check_for_death({type = "environment", pos = pos, node = self.standing_in})
end
end,
})
mobs:spawn_specific("xocean:fish", {"default:water_source"}, {"default:water_flowing","default:water_source"}, 2, 20, 30, 10000, 5, -31000, l_water_level)
mobs:register_egg("xocean:fish", "Tropical Fish (Kob)", "xocean_fish.png", 0)
@ -1793,6 +1794,12 @@ mobs:register_mob("xocean:fish2", {
run_start = 40,
run_end = 100,
},
do_custom = function(self, dtime)
if self.standing_in == "air" then
self.health = self.health - dtime
self:check_for_death({type = "environment", pos = pos, node = self.standing_in})
end
end,
})
mobs:spawn_specific("xocean:fish2", {"default:water_source"}, {"default:water_flowing","default:water_source"}, 2, 20, 30, 10000, 5, -31000, l_water_level)
mobs:register_egg("xocean:fish2", "Tropical Fish (SunStreak)", "xocean_fish2.png", 0)
@ -1833,6 +1840,12 @@ mobs:register_mob("xocean:fish3", {
run_start = 40,
run_end = 100,
},
do_custom = function(self, dtime)
if self.standing_in == "air" then
self.health = self.health - dtime
self:check_for_death({type = "environment", pos = pos, node = self.standing_in})
end
end,
})
mobs:spawn_specific("xocean:fish3", {"default:water_source"}, {"default:water_flowing","default:water_source"}, 2, 20, 30, 10000, 5, -31000, l_water_level)
mobs:register_egg("xocean:fish3", "Tropical Fish (Dasher)", "xocean_fish3.png", 0)
@ -1873,6 +1886,12 @@ mobs:register_mob("xocean:fish4", {
run_start = 40,
run_end = 100,
},
do_custom = function(self, dtime)
if self.standing_in == "air" then
self.health = self.health - dtime
self:check_for_death({type = "environment", pos = pos, node = self.standing_in})
end
end,
})
mobs:spawn_specific("xocean:fish4", {"default:water_source"}, {"default:water_flowing","default:water_source"}, 2, 20, 30, 10000, 5, -31000, l_water_level)
mobs:register_egg("xocean:fish4", "Tropical Fish (Snapper)", "xocean_fish4.png", 0)