mobs:register_spawn("mountain:mountain_monster", {"default:dirt_with_grass"}, 2, -1, 7000, 1, 1000, function(pos, node))
pos.y > 30
return true
mobs:register_spawn("mountain:mountain_monster", {"default:dirt_with_grass"}, 2, -1, 7000, 1, 1000, function(pos, node)
return (pos.y > 30)
end)
sfan5 wrote:That code won't do anything try this:Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
- Code: Select all
mobs:register_spawn("mountain:mountain_monster", {"default:dirt_with_grass"}, 2, -1, 7000, 1, 1000, function(pos, node)
return (pos.y > 30)
end)
Wrestlerpbeast wrote:GUIConfigureWorld: Not allowing focus change.
GUIConfigureWorld: Not allowing focus change.
13:08:51: ERROR[main]: ========== ERROR FROM LUA ===========
13:08:51: ERROR[main]: Failed to load and run script from
13:08:51: ERROR[main]: C:\Documents and Settings\rick\My Documents\Minetest\minetest-0.4.7\bin\..\mods\mobs\init.lua:
13:08:51: ERROR[main]: cannot open C:\Documents and Settings\rick\My Documents\Minetest\minetest-0.4.7\bin\..\mods\mobs\init.lua: No such file or directory
13:08:51: ERROR[main]: =======END OF ERROR FROM LUA ========
13:08:51: ERROR[main]: Server: Failed to load and run C:\Documents and Settings\rick\My Documents\Minetest\minetest-0.4.7\bin\..\mods\mobs\init.lua
13:08:51: ERROR[main]: ModError: Failed to load and run C:\Documents and Settings\rick\My Documents\Minetest\minetest-0.4.7\bin\..\mods\mobs\init.lua
13:08:59: INFO: event_handler(): Ctrl+C, Close Event, Logoff Event or Shutdown Event, shutting down.
cannot open C:\Documents and Settings\rick\My Documents\Minetest\minetest-0.4.7\bin\..\mods\mobs\init.lua: No such file or directory
onpon4 wrote:cannot open C:\Documents and Settings\rick\My Documents\Minetest\minetest-0.4.7\bin\..\mods\mobs\init.lua: No such file or directory
init.lua. It's missing.
I think Windows Explorer by default adds an extra folder when you extract Zip files. That might be the problem. Look in the mobs folder; it should have init.lua and some other files and folders for the mod. If you don't see it there but see it somewhere else, it's whatever folder it's in that should be directly in that mobs folder.
ak399g wrote:How do I create a mob with a plantlike drawtype? I see it uses "visual =" instead of "drawtype".
ak399g wrote:How do I create a mob with a plantlike drawtype? I see it uses "visual =" instead of "drawtype".
PilzAdam wrote:ak399g wrote:How do I create a mob with a plantlike drawtype? I see it uses "visual =" instead of "drawtype".
There is no plantlike drawtype for entities.
Neuromancer wrote:PilzAdam wrote:ak399g wrote:How do I create a mob with a plantlike drawtype? I see it uses "visual =" instead of "drawtype".
There is no plantlike drawtype for entities.
But you can make something that looks just like a plantlike drawtype by doing this:
node_box = {
type = "fixed",
fixed = {
-- {left,bottom,front,right,top,back}
{0, -1/2, -1/2, 0, 1/2, 1/2},
{-1/2, -1/2, 0, 1/2, 1/2, 0}
},
},
ak399g wrote:How do I create a mob with a plantlike drawtype? I see it uses "visual =" instead of "drawtype".
minetest.register_node("entitytest:plantlike_node", {
drawtype = "plantlike",
tiles = {"default_apple.png"},
groups = {not_in_creative_inventory=1},
})
minetest.register_entity("entitytest:plantlike_entity",{
visual = "wielditem",
visual_size = {x=2/3, y=2/3, z=2/3},
textures = {"entitytest:plantlike_node"},
collisionbox = {-1/4, -1/2, -1/4, 1/4, 0, 1/4},
})
minetest.register_tool("entitytest:test_spawner", {
description = "Test Spawner",
inventory_image = "default_nc_front.png",
on_place = function (itemstack, placer, pointed_thing)
minetest.add_entity(pointed_thing.above, "entitytest:plantlike_entity")
return itemstack
end,
})
derpswa99 wrote:Can you please make the mobs have a bit more health, I ask this because anything above a steel sword will 1-shot them, and I want to change to mobf, but I want to stay in simple mobs because it's easy to run on my computer. If you do this or not, thank you.
Users browsing this forum: No registered users and 79 guests