New settings for some parameters
This commit is contained in:
parent
8477a26e66
commit
8f53de3a34
@ -16,7 +16,7 @@ mobs:register_mob("nssm:mordain", {
|
|||||||
sounds = {
|
sounds = {
|
||||||
random = "mordain",
|
random = "mordain",
|
||||||
},
|
},
|
||||||
damage = 4,
|
damage = 6,
|
||||||
jump = true,
|
jump = true,
|
||||||
drops = {
|
drops = {
|
||||||
{name = "nssm:life_energy",
|
{name = "nssm:life_energy",
|
||||||
|
@ -13,7 +13,7 @@ mobs:register_mob("nssm:morde", {
|
|||||||
walk_velocity = 0.5,
|
walk_velocity = 0.5,
|
||||||
reach =3,
|
reach =3,
|
||||||
run_velocity = 3.5,
|
run_velocity = 3.5,
|
||||||
damage = 5,
|
damage = 6,
|
||||||
jump = true,
|
jump = true,
|
||||||
sounds = {
|
sounds = {
|
||||||
random = "morde",
|
random = "morde",
|
||||||
|
127
mobs/morgut.lua
127
mobs/morgut.lua
@ -86,79 +86,80 @@ mobs:register_mob("nssm:morgut", {
|
|||||||
|
|
||||||
self.dir = (self.dir or 0)
|
self.dir = (self.dir or 0)
|
||||||
if (os.time() - self.morgut_timer) > 1 then
|
if (os.time() - self.morgut_timer) > 1 then
|
||||||
|
if self.attack then
|
||||||
|
local s = self.object:getpos()
|
||||||
|
local p = self.attack:getpos()
|
||||||
|
set_animation(self, "punch")
|
||||||
|
local m = 2
|
||||||
|
|
||||||
local s = self.object:getpos()
|
minetest.add_particlespawner(
|
||||||
local p = self.attack:getpos()
|
6, --amount
|
||||||
set_animation(self, "punch")
|
1, --time
|
||||||
local m = 2
|
{x=p.x-0.5, y=p.y-0.5, z=p.z-0.5}, --minpos
|
||||||
|
{x=p.x+0.5, y=p.y+0.5, z=p.z+0.5}, --maxpos
|
||||||
|
{x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, --minvel
|
||||||
|
{x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, --maxvel
|
||||||
|
{x=s.x-p.x, y=s.y-p.y, z=s.z-p.z}, --minacc
|
||||||
|
{x=s.x-p.x, y=s.y-p.y, z=s.z-p.z}, --maxacc
|
||||||
|
0.2, --minexptime
|
||||||
|
0.3, --maxexptime
|
||||||
|
2, --minsize
|
||||||
|
3, --maxsize
|
||||||
|
false, --collisiondetection
|
||||||
|
"roasted_duck_legs.png" --texture
|
||||||
|
)
|
||||||
|
|
||||||
minetest.add_particlespawner(
|
minetest.after(1, function (self)
|
||||||
6, --amount
|
if self.attack:is_player() then
|
||||||
1, --time
|
local pname = self.attack:get_player_name()
|
||||||
{x=p.x-0.5, y=p.y-0.5, z=p.z-0.5}, --minpos
|
local player_inv = minetest.get_inventory({type='player', name = pname})
|
||||||
{x=p.x+0.5, y=p.y+0.5, z=p.z+0.5}, --maxpos
|
|
||||||
{x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, --minvel
|
|
||||||
{x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, --maxvel
|
|
||||||
{x=s.x-p.x, y=s.y-p.y, z=s.z-p.z}, --minacc
|
|
||||||
{x=s.x-p.x, y=s.y-p.y, z=s.z-p.z}, --maxacc
|
|
||||||
0.2, --minexptime
|
|
||||||
0.3, --maxexptime
|
|
||||||
2, --minsize
|
|
||||||
3, --maxsize
|
|
||||||
false, --collisiondetection
|
|
||||||
"roasted_duck_legs.png" --texture
|
|
||||||
)
|
|
||||||
|
|
||||||
minetest.after(1, function (self)
|
if player_inv:is_empty('main') then
|
||||||
if self.attack:is_player() then
|
--minetest.chat_send_all("Inventory empty")
|
||||||
local pname = self.attack:get_player_name()
|
else
|
||||||
local player_inv = minetest.get_inventory({type='player', name = pname})
|
for i = 1,32 do
|
||||||
|
--minetest.chat_send_all("Inventory is not empty")
|
||||||
if player_inv:is_empty('main') then
|
local items = player_inv:get_stack('main', i)
|
||||||
--minetest.chat_send_all("Inventory empty")
|
local n = items:get_name()
|
||||||
else
|
if minetest.get_item_group(n, "eatable")==1 then
|
||||||
for i = 1,32 do
|
local index
|
||||||
--minetest.chat_send_all("Inventory is not empty")
|
local found = 0
|
||||||
local items = player_inv:get_stack('main', i)
|
for j = 1,32 do
|
||||||
local n = items:get_name()
|
if found == 0 then
|
||||||
if minetest.get_item_group(n, "eatable")==1 then
|
if self.inventory[j].num == 0 then
|
||||||
local index
|
--found an empty place
|
||||||
local found = 0
|
found = 2
|
||||||
for j = 1,32 do
|
index = j
|
||||||
if found == 0 then
|
else
|
||||||
if self.inventory[j].num == 0 then
|
--found a corrsponding itemstack
|
||||||
--found an empty place
|
if self.inventory[j].name == n then
|
||||||
found = 2
|
self.inventory[j].num = self.inventory[j].num +1
|
||||||
index = j
|
found = 1
|
||||||
else
|
end
|
||||||
--found a corrsponding itemstack
|
|
||||||
if self.inventory[j].name == n then
|
|
||||||
self.inventory[j].num = self.inventory[j].num +1
|
|
||||||
found = 1
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
if found == 2 then
|
||||||
|
self.inventory[index].name = n
|
||||||
|
self.inventory[index].num = 1
|
||||||
|
end
|
||||||
|
items:take_item()
|
||||||
|
player_inv:set_stack('main', i, items)
|
||||||
end
|
end
|
||||||
if found == 2 then
|
|
||||||
self.inventory[index].name = n
|
|
||||||
self.inventory[index].num = 1
|
|
||||||
end
|
|
||||||
items:take_item()
|
|
||||||
player_inv:set_stack('main', i, items)
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
set_animation(self, "run")
|
||||||
|
self.flag = 1
|
||||||
|
self.morgut_timer = os.time()
|
||||||
|
self.curr_attack = self.attack
|
||||||
|
self.state = ""
|
||||||
|
local pyaw = self.curr_attack: get_look_yaw()
|
||||||
|
self.dir = pyaw
|
||||||
|
self.object:setyaw(pyaw)
|
||||||
|
set_velocity(self, 4)
|
||||||
end
|
end
|
||||||
set_animation(self, "run")
|
end,self)
|
||||||
self.flag = 1
|
end
|
||||||
self.morgut_timer = os.time()
|
|
||||||
self.curr_attack = self.attack
|
|
||||||
self.state = ""
|
|
||||||
local pyaw = self.curr_attack: get_look_yaw()
|
|
||||||
self.dir = pyaw
|
|
||||||
self.object:setyaw(pyaw)
|
|
||||||
set_velocity(self, 4)
|
|
||||||
end
|
|
||||||
end,self)
|
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
on_die = function(self)
|
on_die = function(self)
|
||||||
|
@ -15,7 +15,7 @@ mobs:register_mob("nssm:morwa", {
|
|||||||
sounds = {
|
sounds = {
|
||||||
random = "morwa",
|
random = "morwa",
|
||||||
},
|
},
|
||||||
damage = 6,
|
damage = 8,
|
||||||
jump = true,
|
jump = true,
|
||||||
drops = {
|
drops = {
|
||||||
{name = "nssm:life_energy",
|
{name = "nssm:life_energy",
|
||||||
|
20
spawn.lua
20
spawn.lua
@ -54,10 +54,10 @@ if mymapgenis == 6 then
|
|||||||
else
|
else
|
||||||
|
|
||||||
-- SPIDERS
|
-- SPIDERS
|
||||||
mobs:spawn_specific("nssm:black_widow", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 20, 30, 2200000/mm, 2, -31000, 31000)
|
mobs:spawn_specific("nssm:black_widow", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 20, 30, 4400000/mm, 2, -31000, 31000)
|
||||||
mobs:spawn_specific("nssm:daddy_long_legs", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 30, 10, 2200000/mm, 2, -31000, 31000)
|
mobs:spawn_specific("nssm:daddy_long_legs", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 30, 10, 4400000/mm, 2, -31000, 31000)
|
||||||
mobs:spawn_specific("nssm:tarantula", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 14, 120, 5000000/mm, 1, -31000, 31000)
|
mobs:spawn_specific("nssm:tarantula", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 14, 120, 50000000/mm, 1, -31000, 31000)
|
||||||
mobs:spawn_specific("nssm:uloboros", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 20, 30, 2200000/mm, 1, -31000, 31000)
|
mobs:spawn_specific("nssm:uloboros", {"default:jungle_grass", "default:jungletree", "nssm:web" }, {"air"}, 0, 20, 30, 4400000/mm, 1, -31000, 31000)
|
||||||
|
|
||||||
-- DUCKS
|
-- DUCKS
|
||||||
mobs:spawn_specific("nssm:duck", {"default:dirt_with_grass"}, {"group:flora"}, 10, 20, 50, 1500000/mm, 1, -31000, 40)
|
mobs:spawn_specific("nssm:duck", {"default:dirt_with_grass"}, {"group:flora"}, 10, 20, 50, 1500000/mm, 1, -31000, 40)
|
||||||
@ -98,14 +98,14 @@ end
|
|||||||
-- NSSB SPECIAL
|
-- NSSB SPECIAL
|
||||||
if minetest.get_modpath("nssb") then
|
if minetest.get_modpath("nssb") then
|
||||||
mobs:spawn_specific("nssm:xgaloctopus", {"default:water_source"}, {"nssb:marine_brick"}, 0, 20, 20, 800000/mm, 1, -31000, 0)
|
mobs:spawn_specific("nssm:xgaloctopus", {"default:water_source"}, {"nssb:marine_brick"}, 0, 20, 20, 800000/mm, 1, -31000, 0)
|
||||||
mobs:spawn_specific("nssm:morbat1", {"air"}, {"nssb:morelentir"}, 0, 20, 100, 1000000/mm, 1, -31000, 0)
|
mobs:spawn_specific("nssm:morbat1", {"air"}, {"nssb:morelentir"}, 0, 20, 100, 20000000/mm, 1, -31000, 0)
|
||||||
mobs:spawn_specific("nssm:morbat2", {"air"}, {"nssb:morelentir"}, 0, 20, 100, 1000000/mm, 1, -31000, 0)
|
mobs:spawn_specific("nssm:morbat2", {"air"}, {"nssb:morelentir"}, 0, 20, 100, 20000000/mm, 1, -31000, 0)
|
||||||
mobs:spawn_specific("nssm:morbat3", {"air"}, {"nssb:morelentir"}, 0, 20, 100, 1000000/mm, 1, -31000, 0)
|
mobs:spawn_specific("nssm:morbat3", {"air"}, {"nssb:morelentir"}, 0, 20, 100, 20000000/mm, 1, -31000, 0)
|
||||||
mobs:spawn_specific("nssm:morvy", {"nssb:morentir"}, {"nssb:morentir"}, 0, 20, 120, 1200000/mm, 1, -31000, -93)
|
mobs:spawn_specific("nssm:morvy", {"nssb:morentir"}, {"nssb:morentir"}, 0, 20, 120, 12000000/mm, 1, -31000, -93)
|
||||||
mobs:spawn_specific("nssm:morlu", {"nssb:morentir"}, {"nssb:mornen"}, 0, 20, 80, 700000/mm, 1, -31000, -93)
|
mobs:spawn_specific("nssm:morlu", {"nssb:morentir"}, {"nssb:mornen"}, 0, 20, 80, 700000/mm, 1, -31000, -93)
|
||||||
mobs:spawn_specific("nssm:morde", {"nssb:morenrir"}, {"nssb:mornar"}, 0, 20, 50, 500000/mm, 1, -31000, -93)
|
mobs:spawn_specific("nssm:morde", {"nssb:morenrir"}, {"nssb:mornar"}, 0, 20, 50, 500000/mm, 1, -31000, -93)
|
||||||
mobs:spawn_specific("nssm:mordain", {"nssb:morentir"}, {"nssb:morentir"}, 0, 20, 90, 900000/mm, 1, -31000, .93)
|
mobs:spawn_specific("nssm:mordain", {"nssb:morentir"}, {"nssb:morentir"}, 0, 20, 90, 9000000/mm, 1, -31000, .93)
|
||||||
mobs:spawn_specific("nssm:morgut", {"nssb:morentir"}, {"nssb:morentir"}, 0, 20, 50, 500000/mm, 1, -31000, -93)
|
mobs:spawn_specific("nssm:morgut", {"nssb:morentir"}, {"nssb:morentir"}, 0, 20, 50, 5000000/mm, 1, -31000, -93)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- CAVES
|
-- CAVES
|
||||||
|
Loading…
x
Reference in New Issue
Block a user