[Mod] Simple Mobs [mobs]

ZacAttack
Member
 
Posts: 53
Joined: Tue Apr 30, 2013 14:12

by ZacAttack » Mon May 06, 2013 23:28

OwenBean wrote:Sorry - I get a failed to run init.lua

change name of file to "mobs"
Zdg
 

Nicksahere
New member
 
Posts: 4
Joined: Sun May 05, 2013 21:43

by Nicksahere » Wed May 08, 2013 00:19

Idk what it is but this mod spawns a ton, I mean a TON! I really need help, they lag up my game terribly
 

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

by PilzAdam » Wed May 08, 2013 09:54

Nicksahere wrote:Idk what it is but this mod spawns a ton, I mean a TON! I really need help, they lag up my game terribly

I noticed that too. In the latest dev version fo the Minetest engine huge piles of mobs spawn. That is not intentional.
 

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

by Sokomine » Wed May 08, 2013 14:39

Sheep in a deep valley seemed to reproduce fast:
Image
Might be a client/network bug as after relogin the number of sheep was decresed a bit. In general, lots of mobs gather in pits. Their jumping is too random to "escape" and reach higher ground most of the time.
Last edited by Sokomine on Wed May 08, 2013 14:39, edited 1 time in total.
A list of my mods can be found here.
 

User avatar
kaeza
Member
 
Posts: 2141
Joined: Thu Oct 18, 2012 05:00
GitHub: kaeza
IRC: kaeza diemartin blaaaaargh
In-game: kaeza

by kaeza » Wed May 08, 2013 15:45

Sokomine wrote:Sheep in a deep valley seemed to reproduce fast:
(img)
Might be a client/network bug as after relogin the number of sheep was decresed a bit. In general, lots of mobs gather in pits. Their jumping is too random to "escape" and reach higher ground most of the time.

This also happens with MOBF. It may be that entity duplication bug.
Edit: as a side note, when posting images hosted in ompldr, change the first char in the filename from 't' ("thumbnail") to 'v' ("view"). In your case, http://ompldr.org/taWNrNg becomes http://ompldr.org/vaWNrNg
Last edited by kaeza on Wed May 08, 2013 15:47, edited 1 time in total.
Your signature is not the place for a blog post. Please keep it as concise as possible. Thank you!

Check out my stuff! | Donations greatly appreciated! PayPal | BTC: 1DFZAa5VtNG7Levux4oP6BuUzr1e83pJK2
 

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

by Sokomine » Wed May 08, 2013 18:24

Thanks for the hint with ompldr. I used zimg.eu before, but that seems to be down. The smaller preview image isn't entirely bad; it may help load the page. The "post your screenshots"-thread is close to unreadable for me with its many images.

The sheep in this case might very well have been that entity dublication bug. Some more sheep might have fallen in from the hills around that valley, but not that many.

It's great that entity-entity-collusion is now part of the game so animals no longer wander through each other. That improves the game a lot!
A list of my mods can be found here.
 

User avatar
12Me21
Member
 
Posts: 826
Joined: Tue Mar 05, 2013 00:36

by 12Me21 » Wed May 08, 2013 21:16

12Me21 wrote:You should add cats
This is a signature virus. Add me to your signature so that I can multiply.
Don't ever save anything as a JPEG.
 

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

by Sokomine » Wed May 08, 2013 21:18

Feel free to do a cat model! There are many animals which could be part of MT and for which we don't have a model yet
A list of my mods can be found here.
 

User avatar
Pavel_S
Member
 
Posts: 131
Joined: Sat Apr 06, 2013 11:43

by Pavel_S » Tue May 14, 2013 07:19

 

User avatar
PenguinDad
Member
 
Posts: 122
Joined: Wed Apr 10, 2013 16:46
GitHub: PenguinDad
IRC: PenguinDad GhostDoge
In-game: PenguinDad

by PenguinDad » Wed May 15, 2013 13:07

I have a problem.
When I kill a rat I have no rat in my inventory.
<Cyndra> Programming properly in C++ feels like putting together a jigsaw puzzle
<Cyndra> where the peices don't fit and the picture doesn't matter.
 

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

by PilzAdam » Wed May 15, 2013 13:22

Limux wrote:I have a problem.
When I kill a rat I have no rat in my inventory.

Try rightclicking the rat.
 

User avatar
12Me21
Member
 
Posts: 826
Joined: Tue Mar 05, 2013 00:36

by 12Me21 » Wed May 15, 2013 13:24

Sokomine wrote:Feel free to do a cat model! There are many animals which could be part of MT and for which we don't have a model yet

I don't know how to make models.
This is a signature virus. Add me to your signature so that I can multiply.
Don't ever save anything as a JPEG.
 

User avatar
PenguinDad
Member
 
Posts: 122
Joined: Wed Apr 10, 2013 16:46
GitHub: PenguinDad
IRC: PenguinDad GhostDoge
In-game: PenguinDad

by PenguinDad » Wed May 15, 2013 13:54

PilzAdam wrote:Try rightclicking the rat.

Thanks and you shave a sheep with the same procedure.
<Cyndra> Programming properly in C++ feels like putting together a jigsaw puzzle
<Cyndra> where the peices don't fit and the picture doesn't matter.
 

User avatar
Mossmanikin
Member
 
Posts: 599
Joined: Sun May 19, 2013 16:26

by Mossmanikin » Fri May 24, 2013 12:06

Like it!
Love the sheep, remind me so much of Minecraft.

Noob 4 life!
My stuff
 

User avatar
jojoa1997
Member
 
Posts: 2890
Joined: Thu Dec 13, 2012 05:11

by jojoa1997 » Fri May 24, 2013 12:26

Maybe shears should be added for shearing sheep.
Coding;
1X coding
3X debugging
12X tweaking to be just right
 

User avatar
BrandonReese
Member
 
Posts: 836
Joined: Wed Sep 12, 2012 00:44
GitHub: bremaweb
IRC: BrandonReese
In-game: BrandonReese

by BrandonReese » Fri May 24, 2013 15:12

I had to remove simple mobs from my server. Mobs piled up in low lying areas and were lagging my server like crazy. I know you check how many mobs are in an area when spawning, is it possible to check for the number of mobs in a certain area periodically and start removing mobs if the density to is too high. On my map at one point there were 15+ rats and stone monsters in about a 5x5 area.
 

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

by Sokomine » Fri May 24, 2013 15:21

I'm afraid that's one of the points where mobf is more complex than mobs and where mobs would have to become less simple if checking would be included.

I've encountered the problem as well; on one server with mobs installed, i just fenced off an area that was sourrounded on all other sides by high cliffs. Withhin very short time, lots of sheep had gathered down there. I hope animal right activists will never come there because they'd certainly complain! Sometimes, sheep stack two or three sheep high in certain areas.
A list of my mods can be found here.
 

User avatar
Linxx
Member
 
Posts: 401
Joined: Wed May 16, 2012 00:37

by Linxx » Fri May 24, 2013 16:32

is there a way to make the mod just spawn small patches of mobs? or it's not possible at the moment?
 

Michael Eh?
Member
 
Posts: 282
Joined: Sun Jan 01, 2012 17:21

by Michael Eh? » Sat May 25, 2013 03:21

well I can say i hate this mod... the spawn rate is TOO frickin' high. Also how do we sheer sheep?

Also mice (rats) need to die when encountering water/lava.

How about a mousetrap? 1 steel, 1 wood for 12 traps. Mouse crosses the trap... SNAP! Gone.
The trap would then need to be picked up and place again to reset the trap.

Sheep look like pigs with a hoodie. the snout needs to be longer. :P

Admin controls to /mobpurge [mobname], /mobstop/start [mobname] and something to control gen rate and exclusion zones.
 

User avatar
Zeg9
Member
 
Posts: 608
Joined: Fri Sep 21, 2012 11:02

by Zeg9 » Sat May 25, 2013 08:02

This worked great until some recent update... At the moment it has became kinda unusable due to the spawning problem :/
I made a few (a lot of?) mods for minetest: here is a list.
See also the MT-Faithful texture pack (work in progress).
 

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

by Casimir » Sat May 25, 2013 09:01

Michael Eh? wrote:Sheep look like pigs with a hoodie.

http://www.planetminecraft.com/skin/pig-with-hoodie-1965951/
 

User avatar
thefamilygrog66
Member
 
Posts: 169
Joined: Mon Jul 09, 2012 19:08

by thefamilygrog66 » Sat May 25, 2013 14:15

With some help from Kaeza, I've added a few lines of code to the api.lua file in order to give the mobs a defined life-span, in this case 10 minutes (600 seconds); when each mob reaches that age, it simply disappears.

While not the best solution, it's probably the simplest, and it definitely helps with keeping the mob population under control, thus preventing (or at least reducing) server lag.

On line 30, I added:

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
deathtimer = 0,


And then around line 145 (i.e. in the on_step function), I added:

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
self.deathtimer = self.deathtimer+dtime
if self.deathtimer > 600 then
    self.object:remove()
end


That's it!

If you want mobs to live longer/shorter, simply change the 600 to the number of seconds you prefer.
 

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

by PilzAdam » Sat May 25, 2013 14:28

thefamilygrog66 wrote:With some help from Kaeza, I've added a few lines of code to the api.lua file in order to give the mobs a defined life-span, in this case 10 minutes (600 seconds); when each mob reaches that age, it simply disappears.

While not the best solution, it's probably the simplest, and it definitely helps with keeping the mob population under control, thus preventing (or at least reducing) server lag.

On line 30, I added:

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
deathtimer = 0,


And then around line 145 (i.e. in the on_step function), I added:

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
self.deathtimer = self.deathtimer+dtime
if self.deathtimer > 600 then
    self.object:remove()
end


That's it!

If you want mobs to live longer/shorter, simply change the 600 to the number of seconds you prefer.

I added a lifetimer here: https://github.com/PilzAdam/mobs/commit/3ea8fb5d768403718a4c0fc5e412540709e94d3d
Someone needs to test this.
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

by Inocudom » Sat May 25, 2013 14:35

PilzAdam wrote:
thefamilygrog66 wrote:With some help from Kaeza, I've added a few lines of code to the api.lua file in order to give the mobs a defined life-span, in this case 10 minutes (600 seconds); when each mob reaches that age, it simply disappears.

While not the best solution, it's probably the simplest, and it definitely helps with keeping the mob population under control, thus preventing (or at least reducing) server lag.

On line 30, I added:

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
deathtimer = 0,


And then around line 145 (i.e. in the on_step function), I added:

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
self.deathtimer = self.deathtimer+dtime
if self.deathtimer > 600 then
    self.object:remove()
end


That's it!

If you want mobs to live longer/shorter, simply change the 600 to the number of seconds you prefer.

I added a lifetimer here: https://github.com/PilzAdam/mobs/commit/3ea8fb5d768403718a4c0fc5e412540709e94d3d
Someone needs to test this.


Good idea, PilzAdam. If this new bit of code works out, animals_modpack could find it to be useful as well. Perhaps cheese for mice and hay bundles for sheep could be used to keep them alive for a longer period of time?
 

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

by Sokomine » Sat May 25, 2013 14:36

That may help with lag on servers. Unfortionately, keeping simple mobs as farm animals will become even more difficult then. It already is more a matter of chance right now because the mobs cannot be caught and placed by players. Maybe that rat trap could be extended to sheep and deer so that they could be caught in a cage and carried arround, much like the lasso-catching in mobf.
A list of my mods can be found here.
 

User avatar
thefamilygrog66
Member
 
Posts: 169
Joined: Mon Jul 09, 2012 19:08

by thefamilygrog66 » Sat May 25, 2013 15:30

Sokomine wrote:That may help with lag on servers. Unfortionately, keeping simple mobs as farm animals will become even more difficult then. It already is more a matter of chance right now because the mobs cannot be caught and placed by players. Maybe that rat trap could be extended to sheep and deer so that they could be caught in a cage and carried arround, much like the lasso-catching in mobf.


I agree that a method to transport sheep, as well as a way to "tag" them as being domesticated (and therefore not die after 10 minutes), would be very helpful to add to the mod.
 

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

by PilzAdam » Sat May 25, 2013 15:54

Ok, update: https://github.com/PilzAdam/mobs/commit/853e981992d6acd5276bbcd1ca0201649a6e7f73
Sheeps follow you when you hold wheat now. If you feed them with it, they are marked as tamed and will not despawn.
Also some wheat regrows their wool.
 

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

by Sokomine » Sat May 25, 2013 16:16

Sounds fine!
A list of my mods can be found here.
 

User avatar
Mossmanikin
Member
 
Posts: 599
Joined: Sun May 19, 2013 16:26

by Mossmanikin » Sat May 25, 2013 17:36

Love the update!

Only one thing: isn't the wheat meant to disappear when you feed the sheep?
When I feed them it stays in my inventory...

Noob 4 life!
My stuff
 

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

by PilzAdam » Sat May 25, 2013 17:39

Mossmanikin wrote:Love the update!

Only one thing: isn't the wheat meant to disappear when you feed the sheep?
When I feed them it stays in my inventory...

It was a bug in the engine, fixed here: https://github.com/minetest/minetest/commit/e464f193566b3c4173b44d3bf6c82aa032d9fed7
 

PreviousNext

Return to Mod Releases

Who is online

Users browsing this forum: No registered users and 18 guests

cron