Page 5 of 35

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Fri Feb 27, 2015 22:07
by Linuxdirk
It crashes for me with the latest Git version :(

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
23:03:31: ERROR[main]: ServerError: /home/dirk/.minetest/mods/mobs/api.lua:735: attempt to index field '?' (a nil value)
23:03:31: ERROR[main]: stack traceback:
23:03:31: ERROR[main]:    /home/dirk/.minetest/mods/mobs/api.lua:735: in function </home/dirk/.minetest/mods/mobs/api.lua:710>

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Fri Feb 27, 2015 23:50
by byronarn
Awesome mod. I love it!

One question. Is there a way to change the frequency the spawn of hostile mobs? The game is too easy. I want a challenge to survive. Lol.

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sat Feb 28, 2015 21:01
by TenPlus1
linuxdirk: line 735 adds a number and will not crash, please make sure you have new Minetest 0.4.12 installed and folder is renamed to 'mobs' and not 'mobs-master'...

byronarn: in each mob .api file is a command mobs:register_spawn .. you can change the chance values to make mobs spawn more regularly, or active_object_count to have more in 1 area:

mobs:register_spawn(name, nodes, max_light, min_light, chance, active_object_count, max_height)

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sat Feb 28, 2015 21:15
by Linuxdirk
TenPlus1 wrote:linuxdirk: line 735 adds a number and will not crash, please make sure you have new Minetest 0.4.12 installed and folder is renamed to 'mobs' and not 'mobs-master'...

Wait a second … 0.4.12? That might be the issue. (I should check the news section more often …)

Damn you Massimiliano Torromeo (yes, you! I know you! *g*) for not updating the Arch Linux package in the repositories. It’s out since nearly two weeks!

I’ll try with the latest version :D

Edit: Still randomly crashes with same error message and lines.

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
$ minetest --version
Minetest 0.4.12
Using Irrlicht 1.8.1
Build info: VER=0.4.12 BUILD_TYPE=Release RUN_IN_PLACE=0 USE_GETTEXT=1 USE_SOUND=1 USE_CURL=1 USE_FREETYPE=1 USE_LUAJIT=0 STATIC_SHAREDIR=/usr/share/minetest

$ pwd
/home/dirk/.minetest/mods/mobs

$ git status
On branch master
Your branch is up-to-date with 'origin/master'.
nothing to commit, working directory clean

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sat Feb 28, 2015 22:56
by Linuxdirk
Here’s a screenshot of that message showing the same information as the log file and the console output.

Image

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 02:36
by maikerumine
JUST IN:

I have noticed this twice in mods that fail in 4.12 due to compatibility issues. What has changed? This is quite serious, as different versions will fail on load.

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 09:01
by TenPlus1
I dont understand the error message, on the line in question this is what appears:

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
pos.y = pos.y + 1


... which would not produce that error... do you have any other mods running alongside ??

I have the latest mobs redo mod running on a 0.4.11 server with no errors and a standalone 0.4.12 server with no problems, but will double check everything just incase...

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 09:56
by Linuxdirk
TenPlus1 wrote:I dont understand the error message, on the line in question this is what appears:

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
pos.y = pos.y + 1


I don’t know where you got this from, but since it’s your code I assume you’re right. On 735 it’s …

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 minetest.registered_nodes[minetest.get_node(pos).name].walkable then return end

… and on 710 it’s …

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
action = function(pos, node, _, active_object_count_wider)

The code you mention is on line 719 according to the latest Git version of your mod.

TenPlus1 wrote:do you have any other mods running alongside ??

Of course I have. Here is a German list I maintain in conjunction with my Let’s Play series. It lists all mods I currently use (first value in each row is the mod’s name).

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 10:51
by TenPlus1
Linuxdirk: I've added a few extra checks when spawning mobs which should stop any errors, github and forum download have been updated...

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 11:49
by Linuxdirk
I’ll test it as soon as possible!

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 13:07
by Linuxdirk
Update: Still randomly crashes

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
14:03:33: ERROR[main]: ServerError: /home/dirk/.minetest/mods/mobs/api.lua:736: attempt to index field '?' (a nil value)
14:03:33: ERROR[main]: stack traceback:
14:03:33: ERROR[main]:    /home/dirk/.minetest/mods/mobs/api.lua:736: in function </home/dirk/.minetest/mods/mobs/api.lua:709>

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 13:49
by TenPlus1
Linuxdirk: please test the latest Mobs Redo on a vanilla map with NO mobs loaded... Everything works perfectly here on 0.4.12 and on server 0.4.11 with a multitude of mods active...

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 18:56
by byronarn
byronarn: in each mob .api file is a command mobs:register_spawn .. you can change the chance values to make mobs spawn more regularly, or active_object_count to have more in 1 area:

mobs:register_spawn(name, nodes, max_light, min_light, chance, active_object_count, max_height)

What is the unit of measure for chance? I would assume percentage of chance but I saw a 7000 so that's unlikely. What's the max?

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 19:42
by highbomber
This is great! How would I go about getting these mobs to spawn in the riverdev map generator?
viewtopic.php?f=11&t=9210

Re: [Mod] Mobs Redo [0.2] [mobs]

PostPosted: Sun Mar 01, 2015 20:54
by sofar
TenPlus1 wrote:Inocudom: the init.lua file contains a line for each mob in the pack, if a player or server owner doesn't want a particular mob they can easily comment out the line :)

Am tinkering with mobs that don't expire near certain blocks, like in the Slimes mod so pets could be an option... The mob api is already on github in the Lord of the Test [game] so I wont upload another to confuse coders, I made this pack to add simple mobs to the basic game...


not sure if this was said already, but if you do this, and people track your mod from github (like I do) then you force them to git merge their personal changes.

Better would be to have an optional config.lua that (if exists) is parsed, so that people can keep config files and your source code separated more easily.

Re: [Mod] Mobs Redo [0.2] [mobs]

PostPosted: Sun Mar 01, 2015 21:04
by Linuxdirk
sofar wrote:Better would be to have an optional config.lua that (if exists) is parsed, so that people can keep config files and your source code separated more easily.

I use this for all options in my mods.

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
function getValid(value, default)
    local v = minetest.setting_get(value)
    return (v == nil and default or v)
end

And then I simply use local foo = getValid('my_cool_option', 'my_default_value') which checks if there is an option my_cool_option in minetest.conf and returns its value. If the option is not present in the configuration file it returns my_default_value instead.

For some reason local foo = minetest.setting_get('my_cool_option') or 'my_default_value' for me never worked as expected.

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Sun Mar 01, 2015 21:57
by TenPlus1
linunxdirk: does Mobs Redo work for you when you disable all other mods ?

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Mon Mar 02, 2015 21:01
by Linuxdirk
TenPlus1 wrote:linunxdirk: does Mobs Redo work for you when you disable all other mods ?

Since this is not reproducible I can’t tell fo sure but I used freemove and flew around for 10 minutes so I’d say “it might work”.

Since none of the other mods does something with mobs I’d suspect the world I’m using. It was initially generated by Carbone and I had that other mobs mod active before (it uses the same IDs, right?).

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Tue Mar 03, 2015 20:29
by TenPlus1
No, carbone and mobs redo are incompatible... you would have to somehow disable mobs on carbone before activating mobs redo as they both use different versions of the mob api...

Re: [Mod] Mobs Redo [1.02] [mobs]

PostPosted: Thu Mar 05, 2015 19:24
by TenPlus1
Updated to 1.02... Sheared sheep now re-spawn shaven, Warthogs will attack when threatened, Api improvements...

Re: [Mod] Mobs Redo [1.02] [mobs]

PostPosted: Thu Mar 05, 2015 19:30
by Achilles
Idea:

Is there any chance of an aggressive teleporting mob? Similar to the 'Enderman' mob in MineCraft?

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Thu Mar 05, 2015 21:58
by Linuxdirk
TenPlus1 wrote:No, carbone and mobs redo are incompatible...

I’m not using Carbone anymore. I just use the world initially generated with Carbone.

Could it be that Mobs Redo uses the same IDs for mobs than the mobs mod Carbone uses and tries to re-use the already spawned mods and thus breaks?

Re: [Mod] Mobs Redo [1.01] [mobs]

PostPosted: Thu Mar 05, 2015 22:38
by maikerumine
Linuxdirk wrote:
TenPlus1 wrote:No, carbone and mobs redo are incompatible...

I’m not using Carbone anymore. I just use the world initially generated with Carbone.

Could it be that Mobs Redo uses the same IDs for mobs than the mobs mod Carbone uses and tries to re-use the already spawned mods and thus breaks?


Yep, this was happening to me when I was learning hacking mobs to make my own. The mob mod should have different name like mobx, or moby, or something different as well as the code inside needs to reflect this, then you can run LOADS of mobs and have fun with that. My 2 cents.

Re: [Mod] Mobs Redo [1.02] [mobs]

PostPosted: Fri Mar 06, 2015 05:44
by cHyper
TenPlus1 wrote:Updated to 1.02... Sheared sheep now re-spawn shaven, Warthogs will attack when threatened, Api improvements...


which version of minetest are supported yet?
stable and unstable - dev - also?

Re: [Mod] Mobs Redo [1.02] [mobs]

PostPosted: Fri Mar 06, 2015 08:08
by TenPlus1
cHyper: Mobs Redo 1.02 runs on all versions tested from 0.4.9 to 0.4.12+

Re: [Mod] Mobs Redo [1.02] [mobs]

PostPosted: Fri Mar 06, 2015 18:23
by TenPlus1
1.02b has Npc mob added, doesn't spawn naturally for now so /give mobs:npc to try him out... Kills monsters in area, will attack player if punched, right-click cooked meat or bread to replenish hp, right-click gold ingot for random drop (list inside npc.lua)...

Re: [Mod] Mobs Redo [1.02] [mobs]

PostPosted: Fri Mar 06, 2015 20:38
by cHyper
TenPlus1 wrote:1.02b has Npc mob added, doesn't spawn naturally for now so /give mobs:npc to try him out... Kills monsters in area, will attack player if punched, right-click cooked meat or bread to replenish hp, right-click gold ingot for random drop (list inside npc.lua)...


/give mobs:npc

+1 awesome mod ... best ever...

Re: [Mod] Mobs Redo [1.02] [mobs]

PostPosted: Sat Mar 07, 2015 04:49
by ExeterDad
TenPlus1 wrote:1.02b has Npc mob added, doesn't spawn naturally for now so /give mobs:npc to try him out... Kills monsters in area, will attack player if punched, right-click cooked meat or bread to replenish hp, right-click gold ingot for random drop (list inside npc.lua)...

Heh, heh! I'm not going to tell the kids. Just going to spawn a few near them and watch the fur fly!

Re: [Mod] Mobs Redo [1.03] [mobs]

PostPosted: Tue Mar 10, 2015 12:02
by TenPlus1
More tinkering with the mob api has added the following features:

- fall speed (mese monsters and chickens fall slower than other mobs)
- mob drop (chickens lay eggs, sheep/cows eat grass, oerkki remove torches from floor)
- hurt effects (particle effects added when mob gets hurt in water, lava or outside in the light)
- when mob dies due to any of the above damage it will drop items

Re: [Mod] Mobs Redo [1.03] [mobs]

PostPosted: Tue Mar 10, 2015 15:38
by 12Me21
There should be mobs in the water, like fish (no minecraft squids, please), and maybe some more that spawn in different biomes.