[Mod] Bonemeal [1.1] [bonemeal]

User avatar
Imk
Member
Posts: 363
Joined: Mon Nov 05, 2018 19:15
In-game: Imk
Location: Crimea, Russia
Contact:

Re: [Mod] Bonemeal [1.1] [bonemeal]

by Imk » Post

Code: Select all

11 часов назад
locale 	a0cb8657df change loaded console message 	1 год назад
textures 	c957e1043c added gelatin powder 	1 год назад
README.md 	363ec856ee added 5.0 pine bush sapling and additional flowers 	6 месяцев назад
api.txt 	dd422b6091 add_deco() now adds to item list, set_deco() replaces item list (thanks h-v-smacker) 	1 год назад
depends.txt 	363ec856ee added 5.0 pine bush sapling and additional flowers 	6 месяцев назад
description.txt 	066cad6e25 added mod files and readme's 	2 лет назад
init.lua 	5949d15726 added nil fallback 	11 часов назад
intllib.lua 	153ef883cc added intllib support and french translation 	2 лет назад
license.txt 	066cad6e25 added mod files and readme's 	2 лет назад
lucky_block.lua 	01d71b2b29 add new lb 	11 месяцев назад
mod.conf 	066cad6e25 added mod files and readme's 	2 лет назад
mods.lua 	1299f39126 fix flowers addition :) 	6 месяцев назад
screenshot.png 	9173f39344 update screenshot 	2 лет назад
updated bonemeal on git.
Six months ago. Not quite sure if there's a change or not?

User avatar
Imk
Member
Posts: 363
Joined: Mon Nov 05, 2018 19:15
In-game: Imk
Location: Crimea, Russia
Contact:

Re: [Mod] Bonemeal [1.1] [bonemeal]

by Imk » Post

as before
saw the edit three days ago.

Code: Select all

2019-10-04 02:09:23: ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from mod '' in callback item_OnUse(): /home/imk/minetest/bin/../mods/bonemeal/init.lua:269: bad argument #2 to 'random' (interval is empty)
2019-10-04 02:09:23: ERROR[Main]: stack traceback:
2019-10-04 02:09:23: ERROR[Main]:       [C]: in function 'random'
2019-10-04 02:09:23: ERROR[Main]:       /home/imk/minetest/bin/../mods/bonemeal/init.lua:269: in function 'check_soil'
2019-10-04 02:09:23: ERROR[Main]:       /home/imk/minetest/bin/../mods/bonemeal/init.lua:434: in function 'on_use'
2019-10-04 02:09:23: ERROR[Main]:       /home/imk/minetest/bin/../mods/bonemeal/init.lua:511: in function </home/imk/minetest/bin/../mods/bonemeal/init.lua:493>

User avatar
TenPlus1
Member
Posts: 2803
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [Mod] Bonemeal [1.1] [bonemeal]

by TenPlus1 » Post

please describe what you are doing when this error happens, also have you added anything using the bonemeal api and if so can you show me what.

User avatar
Imk
Member
Posts: 363
Joined: Mon Nov 05, 2018 19:15
In-game: Imk
Location: Crimea, Russia
Contact:

Re: [Mod] Bonemeal [1.1] [bonemeal]

by Imk » Post

I've already told you and shown you screenshots
viewtopic.php?p=358376#p358376

Nothing is added.
only the textures bonemeal_bone (64) have been replaced (this shouldn't affect the job in any way!!!)

client win: minetest-5.1.0-3ad9a8f-win64
server ubuntu (teracrime.ddns.net:30008): version 5.1.0-dev-61e9c1b-dirty

the client can be downloaded from our section viewtopic.php?f=23&t=2105

I'm gonna bring it here in Russian to England
Download the 64bit client to Win XP,7,10
Googol
MEGA
ARCHIVE PASSWORD: supernova.pp.ua

I'll explain it all differently.
bonemeal_item using on the ground ethereal:crystal_dirt,ethereal:fiery_dirt the server is crash
ethereal the other lands are working properly.

User avatar
Imk
Member
Posts: 363
Joined: Mon Nov 05, 2018 19:15
In-game: Imk
Location: Crimea, Russia
Contact:

Re: [Mod] Bonemeal [1.1] [bonemeal]

by Imk » Post

The latest mod update gives an error
I don't know the reason.
2019-10-04 23:25:19: ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from mod '' in callback item_OnUse(): /home/imk/minetest/bin/../mods/bonemeal/init.lua:269: bad argument #2 to 'random' (interval is empty)
2019-10-04 23:25:19: ERROR[Main]: stack traceback:
2019-10-04 23:25:19: ERROR[Main]: [C]: in function 'random'
2019-10-04 23:25:19: ERROR[Main]: /home/imk/minetest/bin/../mods/bonemeal/init.lua:269: in function 'check_soil'
2019-10-04 23:25:19: ERROR[Main]: /home/imk/minetest/bin/../mods/bonemeal/init.lua:434: in function 'on_use'
2019-10-04 23:25:19: ERROR[Main]: /home/imk/minetest/bin/../mods/bonemeal/init.lua:511: in function </home/imk/minetest/bin/../mods/bonemeal/init.lua:493>
but the mistakes are the same.

User avatar
TenPlus1
Member
Posts: 2803
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [Mod] Bonemeal [1.1] [bonemeal]

by TenPlus1 » Post

lmk - I've updated to the latest 5.1 dev and spammed bonemeal on every type of dirt and surface for 20 minutes and cannot reproduce the above error, so what I have done is add some nil checks in place just-in-case it's something to do with your code or mods loaded in world and updated git page and contentdb downloads.

User avatar
runs
Member
Posts: 1748
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy

Re: [Mod] Bonemeal [1.1] [bonemeal]

by runs » Post

i thinks is related to #grass, that it is nil or 0. Maybe a mod that adds some type of node block.
Day 42 of the quarantine

User avatar
TenPlus1
Member
Posts: 2803
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [Mod] Bonemeal [1.1] [bonemeal]

by TenPlus1 » Post

runs - that was the latest nil checks I added so it automatically defaults to 0 to stop any errors... I don't know if lmk is using mods to alter the bonemeal lists.

User avatar
Imk
Member
Posts: 363
Joined: Mon Nov 05, 2018 19:15
In-game: Imk
Location: Crimea, Russia
Contact:

Re: [Mod] Bonemeal [1.1] [bonemeal]

by Imk » Post

I'll write down a list of mods pm

ThorfinnS
Member
Posts: 241
Joined: Mon Feb 25, 2019 22:05
GitHub: ThorfinnS

Re: [Mod] Bonemeal [1.1] [bonemeal]

by ThorfinnS » Post

Is there a plan to incorporate the other dirt varieties? So for instance dry_dirt or dry_dirt_with_grass might drop bones, too? Not sure I see a good way to do it generally, like using groups, but it could be handled the same way you decide which nodes are appropriate for hoe, or which are checked to see if they are sufficiently close to water to become _wet.

Oh, and a suggestion. Maybe the bone drop could be in addition to the dirt drop? So if you dig dirt, you always get dirt, but sometimes you also get a bone?

User avatar
TenPlus1
Member
Posts: 2803
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [Mod] Bonemeal [1.1] [bonemeal]

by TenPlus1 » Post

that's how it currently works, for each dirt block you dig there's a chance of a bone, also you can use the api to at newer dirt decorations. ethereal mod turns it's dry dirt into normal dirt when near water so I'll probably add the newer 5.1 dry dirt onto the same abm.

ThorfinnS
Member
Posts: 241
Joined: Mon Feb 25, 2019 22:05
GitHub: ThorfinnS

Re: [Mod] Bonemeal [1.1] [bonemeal]

by ThorfinnS » Post

TenPlus1 wrote:that's how it currently works, for each dirt block you dig there's a chance of a bone, also you can use the api to at newer dirt decorations. ethereal mod turns it's dry dirt into normal dirt when near water so I'll probably add the newer 5.1 dry dirt onto the same abm.
I just meant there's maxitems=1, so you get either a bone or a block of dirt, never both. Maybe there/s a good reason for it; it just seems to me that if you dig a hole, you should get dirt, and maybe if you are lucky, a bone.

User avatar
TenPlus1
Member
Posts: 2803
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [Mod] Bonemeal [1.1] [bonemeal]

by TenPlus1 » Post

Ahh, i've done it that way so you cant spam dig dirt blocks and get both which I consider cheating :) It's either/or unless you want to manually change it for your world by setting maxitems=2.

ThorfinnS
Member
Posts: 241
Joined: Mon Feb 25, 2019 22:05
GitHub: ThorfinnS

Re: [Mod] Bonemeal [1.1] [bonemeal]

by ThorfinnS » Post

Oh, I see.

Have to be a pretty strange world where dirt was so rare that repeatedly placing and digging the same block would be more efficacious than digging new soil.

Kind of like I've seen people place and dig grass, dry grass and junglegrass just to get the seed drops rather than just digging new grass. Despite it being MUCH slower...

ThorfinnS
Member
Posts: 241
Joined: Mon Feb 25, 2019 22:05
GitHub: ThorfinnS

Re: [Mod] Bonemeal [1.1] [bonemeal]

by ThorfinnS » Post

What am I doing wrong?

Code: Select all

if(minetest.registered_items["bonemeal:mulch"] ~= nil) then
	bonemeal:add_crop({{'ts_crops:crowberry_', 4}})
end
Hovering over the growth stages shows 'ts_crops:crowberry_1', etc., as expected. The crops mature on their own just fine. The mulch in inventory decrements, but it looks to be doing nothing. I'm in full sun.

[EDIT]
Yes, there is an optional depend on bonemeal.
[/EDIT]

User avatar
TenPlus1
Member
Posts: 2803
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [Mod] Bonemeal [1.1] [bonemeal]

by TenPlus1 » Post

Try...

Code: Select all

if minetest.get_modpath("bonemeal") then
	bonemeal:add_crop({
		{"ts_crops:crowberry_", 4},
	})
end

ThorfinnS
Member
Posts: 241
Joined: Mon Feb 25, 2019 22:05
GitHub: ThorfinnS

Re: [Mod] Bonemeal [1.1] [bonemeal]

by ThorfinnS » Post

Thanks.

Turns out it was just that my mod.conf had a typo for "optional_depends".

Is the modpath the accepted way to do that? I thought that tested only for the existence of the mod in the mods folder, not that it was enabled in the particular game. Do I have that backwards? That's why I was using the registered item -- to make sure that bonemeal was not only enabled, but it had been properly loaded first.

User avatar
TenPlus1
Member
Posts: 2803
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [Mod] Bonemeal [1.1] [bonemeal]

by TenPlus1 » Post

If you have a dependency on bonemeal it loads it first before ts_crops, but generally I'll use the modpath check to be sure it's enabled first before using the api.

User avatar
Imk
Member
Posts: 363
Joined: Mon Nov 05, 2018 19:15
In-game: Imk
Location: Crimea, Russia
Contact:

Re: [Mod] Bonemeal [1.1] [bonemeal]

by Imk » Post

the last update disappeared my problem )))))))))))

Post Reply

Who is online

Users browsing this forum: No registered users and 8 guests