[Mod] Simple Mobs [mobs]

Dukie
New member
 
Posts: 3
Joined: Sat Nov 16, 2013 19:22

by Dukie » Sat Nov 16, 2013 19:53

PilzAdam wrote:Fire is part of minetest_game, so you dont need to install it as an external mod.


Thanks! I found that out in the few minutes after I posted.. The "find" command works wonders, eh? ;-)

So - Now I've enabled the mod, and when I fire up the server it bonks out, :(

I grabbed Minetest via github.com a few nights ago, so it's a fairly new build.

I grabbed the Simple Mobs mod today via:
$ wget -O simplemobs.zip https://github.com/PilzAdam/mobs/zipball/master

Once I unzipped it, I moved it to the mobs directory:
$ mv PilzAdam-mobs-c49cc47 simplemobs
$ mv simplemobs /home/minetest/minetest_server/minetest-minetest-bb54e2c/mods/

I then added "load_mod_simplemobs = true" to my "/home/minetest/minetest_server/minetest-minetest-bb54e2c/worlds/world/world.mt" file.

And when I start the server, I get the following:
-snip-
Automatically selecting world at [/home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../worlds/world]
14:40:41: ERROR[main]: ========== ERROR FROM LUA ===========
14:40:41: ERROR[main]: Failed to load and run script from
14:40:41: ERROR[main]: /home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../mods/simplemobs/init.lua:
14:40:41: ERROR[main]: ...est-minetest-bb54e2c/bin/../mods/simplemobs/init.lua:1: attempt to concatenate a nil value
14:40:41: ERROR[main]: stack traceback:
14:40:41: ERROR[main]: ...est-minetest-bb54e2c/bin/../mods/simplemobs/init.lua:1: in main chunk
14:40:41: ERROR[main]: =======END OF ERROR FROM LUA ========
14:40:41: ERROR[main]: Server: Failed to load and run /home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../mods/simplemobs/init.lua
14:40:41: ERROR[main]: ERROR: An unhandled exception occurred: ModError: Failed to load and run /home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../mods/simplemobs/init.lua

In thread 7fbb13658740:
/root/minetest/minetest-minetest-bb54e2c/src/main.cpp:1854: int main(int, char**): Assertion '0' failed.
Debug stacks:
DEBUG STACK FOR THREAD 7fbb13658740:
#0 int main(int, char**)
(Leftover data: #1 Dedicated server branch)
Aborted (core dumped)
-snip-

$ /home/minetest/minetest_server/minetest_server.bin --version
minetestserver 0.4.7-dev
Build info: VER=0.4.7-dev BUILD_TYPE=Release RUN_IN_PLACE=1 USE_GETTEXT=0 USE_SOUND=0 USE_CURL=1 USE_FREETYPE=0 USE_LUAJIT=0 STATIC_SHAREDIR=.

Any ideas or suggestions would be most appreciated, :)
Last edited by Dukie on Sat Nov 16, 2013 20:00, edited 1 time in total.
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Sat Nov 16, 2013 21:07

Dukie wrote:
PilzAdam wrote:Fire is part of minetest_game, so you dont need to install it as an external mod.


Thanks! I found that out in the few minutes after I posted.. The "find" command works wonders, eh? ;-)

So - Now I've enabled the mod, and when I fire up the server it bonks out, :(

I grabbed Minetest via github.com a few nights ago, so it's a fairly new build.

I grabbed the Simple Mobs mod today via:
$ wget -O simplemobs.zip https://github.com/PilzAdam/mobs/zipball/master

Once I unzipped it, I moved it to the mobs directory:
$ mv PilzAdam-mobs-c49cc47 simplemobs
$ mv simplemobs /home/minetest/minetest_server/minetest-minetest-bb54e2c/mods/

I then added "load_mod_simplemobs = true" to my "/home/minetest/minetest_server/minetest-minetest-bb54e2c/worlds/world/world.mt" file.

And when I start the server, I get the following:
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
-snip-
Automatically selecting world at [/home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../worlds/world]
14:40:41: ERROR[main]: ========== ERROR FROM LUA ===========
14:40:41: ERROR[main]: Failed to load and run script from
14:40:41: ERROR[main]: /home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../mods/simplemobs/init.lua:
14:40:41: ERROR[main]: ...est-minetest-bb54e2c/bin/../mods/simplemobs/init.lua:1: attempt to concatenate a nil value
14:40:41: ERROR[main]: stack traceback:
14:40:41: ERROR[main]:  ...est-minetest-bb54e2c/bin/../mods/simplemobs/init.lua:1: in main chunk
14:40:41: ERROR[main]: =======END OF ERROR FROM LUA ========
14:40:41: ERROR[main]: Server: Failed to load and run /home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../mods/simplemobs/init.lua
14:40:41: ERROR[main]: ERROR: An unhandled exception occurred: ModError: Failed to load and run /home/minetest/minetest_server/minetest-minetest-bb54e2c/bin/../mods/simplemobs/init.lua

In thread 7fbb13658740:
/root/minetest/minetest-minetest-bb54e2c/src/main.cpp:1854: int main(int, char**): Assertion '0' failed.
Debug stacks:
DEBUG STACK FOR THREAD 7fbb13658740:
#0  int main(int, char**)
(Leftover data: #1  Dedicated server branch)
Aborted (core dumped)
-snip-

$ /home/minetest/minetest_server/minetest_server.bin --version
minetestserver 0.4.7-dev
Build info: VER=0.4.7-dev BUILD_TYPE=Release RUN_IN_PLACE=1 USE_GETTEXT=0 USE_SOUND=0 USE_CURL=1 USE_FREETYPE=0 USE_LUAJIT=0 STATIC_SHAREDIR=.


Any ideas or suggestions would be most appreciated, :)

Rename the modfolder to "mobs". More info: https://forum.minetest.net/viewtopic.php?id=6450
 

jenova99sephiros
Member
 
Posts: 158
Joined: Sat Aug 03, 2013 15:16
In-game: Jenova

by jenova99sephiros » Sat Nov 16, 2013 22:12

good mod
I english google translator
 

Dukie
New member
 
Posts: 3
Joined: Sat Nov 16, 2013 19:22

by Dukie » Sun Nov 17, 2013 04:40

PilzAdam wrote:Rename the modfolder to "mobs". More info: https://forum.minetest.net/viewtopic.php?id=6450


That did it! Thanks very much! :)

Time to go read-up on naming conventions, :)
 

wcwyes
Member
 
Posts: 145
Joined: Wed Jul 31, 2013 22:42

by wcwyes » Sun Nov 17, 2013 20:55

wcwyes wrote:Is there a way to add a function to the spawn command? Like
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("dwarves:dwarf", {"default:stone"}, 3, -1, 7000, 3, -7000)
If spawn then
    local name=dwarves:dwarf
    if minetest.get_node(pos.x-2, pos.y, pos.z).name=="air" then
        minetest.env:add_entity(pos.x-2, pos.y, pos.z, name)
    end
    if minetest.get_node(pos.x+2, pos.y, pos.z).name=="air" then
        minetest.env:add_entity(pos.x+2, pos.y, pos.z, name)
    end
    if minetest.get_node(pos.x, pos.y, pos.z-2).name=="air" then
        minetest.env:add_entity(pos.x, pos.y, pos.z-2, name)
    end
    if minetest.get_node(pos.x, pos.y, pos.z+2).name=="air" then
        minetest.env:add_entity(pos.x, pos.y, pos.z+2, name)
    end
end

I know this isn't how it's done but it's a start. I only know of two other options, of one which is improper programming methods, the other just more complicated. I would rather keep it in the mobs family.

I've got it loading but it doesn't seem to do anything,
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
    attack_type = "dogfight",
    action = function(pos)
    function dwarves.scatter(pos)
        if minetest.get_node(pos.x-2).name=="air" then
            minetest.env:add_entity(pos.x-2, {name=dwarves:dwarf}),
        end
        if minetest.get_node(pos.x+2).name=="air" then
            minetest.env:add_entity(pos.x+2, {name=dwarves:dwarf}),
        end
        if minetest.get_node(pos.z-2).name=="air" then
            minetest.env:add_entity(pos.z-2, {name=dwarves:dwarf})
        end
        if minetest.get_node(pos.z+2).name=="air" then
            minetest.env:add_entity(pos.z+2, {name=dwarves:dwarf}),
        end
        minetest.env:remove_entity(pos)
        end
end,
help please.
Last edited by wcwyes on Mon Nov 18, 2013 06:28, edited 1 time in total.
 

User avatar
AndrOn
Member
 
Posts: 38
Joined: Fri May 31, 2013 22:32

by AndrOn » Sat Nov 23, 2013 14:08

hey as I usually do I modified some of the code for my own game so that the mobs would drop the items when killed by an arrow (from throwing mod), instead of losing it, and found it much funnier, because now hunting has a point

In mobs/api you just replace the :

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
 if self.object:get_hp() <= 0 then ......................... end


by:
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
            if self.object:get_hp() <= 0 then
                if hitter and hitter:is_player() and hitter:get_inventory() then
                    for _,drop in ipairs(self.drops) do
                        if math.random(1, drop.chance) == 1 then
                            hitter:get_inventory():add_item("main", ItemStack(drop.name.." "..math.random(drop.min, drop.max)))
                        end
                    end
                else
                    for _,drop in ipairs(self.drops) do
                        if math.random(1, drop.chance) == 1
                        then
                            minetest.env:add_item(self.object:getpos(), drop.name.." "..math.random(drop.min, drop.max))
                        end
                    end
                end
               
            end


Basically, it drops the item when the mob dies, but i've not tested every possible death. Also, you may not want to use it on a server because items will be also dropped when light kills the mobs, causing random items drops everywhere.

I'm also going to try and use it for mob farming ;) I replaced the drops to be more interesting to farm.
sorry for bad english
 

User avatar
Nightshade
Member
 
Posts: 25
Joined: Thu Oct 24, 2013 15:25

by Nightshade » Mon Dec 02, 2013 18:11

What do I need to change to get the mobs to spawn more frequently?
 

ElectricSolstice
Member
 
Posts: 90
Joined: Tue Aug 20, 2013 02:00

by ElectricSolstice » Thu Dec 05, 2013 17:31

Nightshade wrote:What do I need to change to get the mobs to spawn more frequently?


I'm guessing change the chance in mob.register_spawn on whichever monster you want to spawn more. I'm guessing a lower number would make it spawn more often because it uses an abm to spawn the monsters. For example,

change
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("mobs:dirt_monster", {"default:dirt_with_grass"}, 3, -1, 7000, 3, 31000)

to
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("mobs:dirt_monster", {"default:dirt_with_grass"}, 3, -1, 3000, 3, 31000)


and I think they should spawn a little more than twice as they already do. However, I haven't tried it yet, so you'll have to tweak that number to your desire.
 

george90867
Member
 
Posts: 25
Joined: Fri Jul 26, 2013 17:42

by george90867 » Thu Dec 05, 2013 20:34

is it in 0.4.8?
 

User avatar
Nightshade
Member
 
Posts: 25
Joined: Thu Oct 24, 2013 15:25

by Nightshade » Thu Dec 05, 2013 20:37

ElectricSolstice wrote:
Nightshade wrote:What do I need to change to get the mobs to spawn more frequently?


I'm guessing change the chance in mob.register_spawn on whichever monster you want to spawn more. I'm guessing a lower number would make it spawn more often because it uses an abm to spawn the monsters. For example,

change
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("mobs:dirt_monster", {"default:dirt_with_grass"}, 3, -1, 7000, 3, 31000)

to
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("mobs:dirt_monster", {"default:dirt_with_grass"}, 3, -1, 3000, 3, 31000)


and I think they should spawn a little more than twice as they already do. However, I haven't tried it yet, so you'll have to tweak that number to your desire.

Thanks, Electric. I'll test it out some time. I just wasn't sure which value in that mess to change (I'm not a coder...)
Last edited by Nightshade on Thu Dec 05, 2013 20:37, edited 1 time in total.
 

Temperest
Member
 
Posts: 651
Joined: Tue Nov 15, 2011 23:13
GitHub: Uberi

by Temperest » Fri Dec 06, 2013 00:30

george90867 wrote:is it in 0.4.8?


Nope, this is still a separate mod.
WorldEdit 1.0 released

The Mesecons Laboratory - the art of Mesecons circuitry
Latest article: Mesecons Basics.
 

Ariel
New member
 
Posts: 4
Joined: Fri Dec 13, 2013 03:51

by Ariel » Fri Dec 13, 2013 21:12

How to install this mod?
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Fri Dec 13, 2013 21:13

Ariel wrote:How to install this mod?

Like every other mod: http://dev.minetest.net/Installing_Mods
Also this is relevant for this mod: https://forum.minetest.net/viewtopic.php?id=6450
 

User avatar
MirceaKitsune
Member
 
Posts: 809
Joined: Sat May 21, 2011 22:31
GitHub: MirceaKitsune
IRC: Taoki
In-game: MirceaKitsune

by MirceaKitsune » Fri Dec 13, 2013 22:01

From what I understood on IRC, PilzAdam isn't working on this mod any more. If that's correct, anyone else interested in maintaining it, and maybe adding more to it? I love this and would hate to see it die. I heard there's already a fork, but didn't look into it yet.
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Fri Dec 13, 2013 22:53

MirceaKitsune wrote:From what I understood on IRC, PilzAdam isn't working on this mod any more. If that's correct, anyone else interested in maintaining it, and maybe adding more to it? I love this and would hate to see it die. I heard there's already a fork, but didn't look into it yet.

You get this wrong, not "working on it" means not adding new features to it. Im still "maintaining" it, i.e. fixing bugs and the like.

And where is that fork?
 

User avatar
MirceaKitsune
Member
 
Posts: 809
Joined: Sat May 21, 2011 22:31
GitHub: MirceaKitsune
IRC: Taoki
In-game: MirceaKitsune

by MirceaKitsune » Fri Dec 13, 2013 22:58

PilzAdam wrote:You get this wrong, not "working on it" means not adding new features to it. Im still "maintaining" it, i.e. fixing bugs and the like.

And where is that fork?


Ah, my mistake. And I thought you mentioned a fork today, but I forgot the name. Or I misunderstood something... that happens a lot these days >.>
Last edited by MirceaKitsune on Fri Dec 13, 2013 22:58, edited 1 time in total.
 

User avatar
Casimir
Member
 
Posts: 1101
Joined: Fri Aug 03, 2012 16:59

by Casimir » Sat Dec 14, 2013 03:03

I'm using Electric Solstices version.
https://github.com/ElectricSolstice/mobs

Wouldn't it be better to separate the api and the mobs? So everyone can write custom creatures based on your mod?
 

jenova99sephiros
Member
 
Posts: 158
Joined: Sat Aug 03, 2013 15:16
In-game: Jenova

by jenova99sephiros » Sat Dec 14, 2013 09:43

What use 2d monster?
I english google translator
 

ElectricSolstice
Member
 
Posts: 90
Joined: Tue Aug 20, 2013 02:00

by ElectricSolstice » Mon Dec 16, 2013 05:09

Casimir wrote:I'm using Electric Solstices version.
https://github.com/ElectricSolstice/mobs

Wouldn't it be better to separate the api and the mobs? So everyone can write custom creatures based on your mod?


I haven't tried it but I think you could already use this mod as a dependancy to try writing your own mods with monsters. Also, I think only in my version of mobs, you also can use your configuration file to control which monsters spawn.
For example, if you didn't want dungeon masters spawning, you could add to minetest.conf (make sure minetest is not running when you make this change, else it won't save)
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_dungeon_master_spawn = false

I think people can already create custom mods using this mod as a dependancy, so correct me if I'm wrong about this. If I'm right about that, then what's the point of seperating the default api and default monsters?

Were you wanting something along the lines of not including the default monsters and only the monsters of other mods? If so, do you think a single configuration option to turn off the spawning of all included default monsters would be an acceptable solution?
Last edited by ElectricSolstice on Mon Dec 16, 2013 05:32, edited 1 time in total.
 

ElectricSolstice
Member
 
Posts: 90
Joined: Tue Aug 20, 2013 02:00

by ElectricSolstice » Mon Dec 16, 2013 05:29

PilzAdam wrote:
MirceaKitsune wrote:From what I understood on IRC, PilzAdam isn't working on this mod any more. If that's correct, anyone else interested in maintaining it, and maybe adding more to it? I love this and would hate to see it die. I heard there's already a fork, but didn't look into it yet.

You get this wrong, not "working on it" means not adding new features to it. Im still "maintaining" it, i.e. fixing bugs and the like.

And where is that fork?


As far as I can tell, it's been half a year since any commit has been added (this would include "maintainance"), unless the commits are going to a different site than git. Also, looks like someone is trying to add turtles and swans and whatever else to their own version of mobs.
Here's the network of the forks, with
https://github.com/PilzAdam/mobs/network
Out of the 3, looks like sokomine's version might be an actual fork rather than minor changes or fixes. All his changes are under the add_animals branch.

If all these changes are merged back up, then I guess they're not forks. However, with sokomine trying to add new animals to his version of the mod instead of creating a custom mod depending on this one, I personally consider it a fork.
 

Sokomine
Member
 
Posts: 2980
Joined: Sun Sep 09, 2012 17:31

by Sokomine » Mon Dec 16, 2013 07:02

ElecricSolstice wrote:someone is trying to add turtles and swans and whatever else to their own version of mobs

Those mobs are models AspireMint did for Minetest. I tried them first on simple mobs because AspireMint wasn't able to run mobf at the time. Plus servers at max run simple mobs and almost never mobf :-(. I wasn't satisfied with the simple mobs version though - the movements and behaviour of the animals just didn't fit (ever see a turtle jump up?). It's not even convincing for the sheep that come with it. The sand- and dirtmobs (including their relatives) move pretty convincingly.

I wouldn't call my version a fork (though technically it is) because all it does is add those new mobs. There are no api changes.
A list of my mods can be found here.
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Mon Dec 16, 2013 18:08

ElectricSolstice wrote:
PilzAdam wrote:
MirceaKitsune wrote:From what I understood on IRC, PilzAdam isn't working on this mod any more. If that's correct, anyone else interested in maintaining it, and maybe adding more to it? I love this and would hate to see it die. I heard there's already a fork, but didn't look into it yet.

You get this wrong, not "working on it" means not adding new features to it. Im still "maintaining" it, i.e. fixing bugs and the like.

And where is that fork?


As far as I can tell, it's been half a year since any commit has been added (this would include "maintainance"), unless the commits are going to a different site than git. Also, looks like someone is trying to add turtles and swans and whatever else to their own version of mobs.
Here's the network of the forks, with
https://github.com/PilzAdam/mobs/network
Out of the 3, looks like sokomine's version might be an actual fork rather than minor changes or fixes. All his changes are under the add_animals branch.

If all these changes are merged back up, then I guess they're not forks. However, with sokomine trying to add new animals to his version of the mod instead of creating a custom mod depending on this one, I personally consider it a fork.

Oh..... I forgot about your changes..... sorry.
The problem is that I just dont have enough time to test them. I guess I can just merge them when people will test it a bit.
 

User avatar
ak399g
Member
 
Posts: 160
Joined: Tue Jul 30, 2013 02:36
In-game: SAFR

by ak399g » Sun Dec 22, 2013 19:53

Four questions:
1.) Possible to create flying mobs?
2.) Possible to have certain mobs jump higher than others?
3.) How to change the Dungeon Master's fireball attack to only igniting flammable objects and air instead of every node?
4.) When I shoot a mob to death with your throwing mod, they don't drop anything.
Last edited by ak399g on Mon Dec 23, 2013 00:46, edited 1 time in total.
aka SAFR
 

User avatar
Dopium
Member
 
Posts: 233
Joined: Sat Jun 09, 2012 15:43

by Dopium » Mon Dec 23, 2013 01:41

Just gotta say the tree monster is really cool, on family games it had my niece in a real panic last night. We all had a good laugh at her freaking out lol. Great mod and lightweight too, perfect for family games night
Running @1.19 MHz, 128 bytes of RAM and interchangeable 4kb ROM carts!
 

hampa16
Member
 
Posts: 192
Joined: Sat Jun 29, 2013 04:20

by hampa16 » Mon Dec 23, 2013 03:32

PilzAdam wrote:
OwenBean wrote:Any idea why im getting my error?

Did you renamed the folder into "mobs"?
Please give me more information.
I did. i got an error. REMOVE THIS MOD<------------------------------Don't hate.
Rex 2 Double 9
=RomanFox2=
SoulKiller35
 

User avatar
wtfsamcrap
Member
 
Posts: 25
Joined: Mon Dec 09, 2013 21:23

by wtfsamcrap » Mon Dec 23, 2013 23:22

I cant find mobs help D:
Mods
 

User avatar
Krock
Member
 
Posts: 3598
Joined: Thu Oct 03, 2013 07:48
GitHub: SmallJoker

by Krock » Tue Dec 24, 2013 10:26

wtfsamcrap wrote:I cant find mobs help D:

Activate it in your world configuration and you should see it in the world.
Newest Win32 builds - Find a mod - All my mods
ALL YOUR DONATION ARE BELONG TO PARAMAT (Please support him and Minetest)
New DuckDuckGo !bang: !mtmod <keyword here>
 

User avatar
LuxAtheris
Member
 
Posts: 169
Joined: Fri Oct 25, 2013 00:54

by LuxAtheris » Tue Dec 24, 2013 14:57

Well the fact that i didn't even saw any dungeon master :/
Believe you can and you’re halfway there.
 

User avatar
AMMOnym
Member
 
Posts: 682
Joined: Tue Sep 10, 2013 14:18
IRC: AMMOnym
In-game: AMMOnym

by AMMOnym » Fri Dec 27, 2013 11:50

Hello, this mod is awesome but can u add new mob "Yeti" becouse if i use mapgen and i go to snow biome, is here a little bit mobs.That yeti can have Dungeon master Mesh and i make a texture: Image that yeti can be very slow but strong and can throw snowball (but i think than that will be strange)
Last edited by AMMOnym on Fri Dec 27, 2013 12:09, edited 1 time in total.
 

User avatar
LuxAtheris
Member
 
Posts: 169
Joined: Fri Oct 25, 2013 00:54

by LuxAtheris » Mon Dec 30, 2013 00:30

Can you add a spawner please?
Believe you can and you’re halfway there.
 

PreviousNext

Return to Mod Releases

Who is online

Users browsing this forum: No registered users and 14 guests

cron