Page 1 of 4

[Mod] Minecraft like item drop/pick up [item_drop]

Posted: Fri Aug 03, 2012 08:53
by PilzAdam
Hello everyone!
I have made a mod that adds Minecraft like item drop/pick up to Minetest. All you have to do is download and install the mod. Thats it!

License:
WTFPL applies to all parts

Dependencies:
None, you can use it with every mod/game/whatever.

GitHub:
https://github.com/PilzAdam/item_drop

Download:
https://github.com/PilzAdam/item_drop/zipball/master

Old versions:

Posted: Fri Aug 03, 2012 12:52
by Bas080
init lua:3: bar argument #1 to

EDIT: Works great. I use the pickup functionality. Not the drop on dig.

Posted: Fri Aug 03, 2012 13:17
by PilzAdam
Bas080 wrote:init lua:3: bar argument #1 to
Is this an error message?

Posted: Fri Aug 03, 2012 13:47
by Spots
didn't get an error message but with this mod installed when i tried to craft it would reset what i had in the crafting area and wouldn't let me change any of it out to make new items

Posted: Fri Aug 03, 2012 15:11
by Mallot1
i dont know what minecraft like item/drop is please be more specific.

Posted: Fri Aug 03, 2012 15:43
by PilzAdam
Mallot1 wrote:i dont know what minecraft like item/drop is please be more specific.
When you dig a block it dont appears in your inventory but it falls down as a item and you can pick it up by walking over it.

Posted: Fri Aug 03, 2012 16:05
by Spots
it's really handy when cutting down trees and the decay kicks in you dont have to pick everyone up you just walk over them

Posted: Fri Aug 03, 2012 16:09
by PilzAdam
Spots wrote:it's really handy when cutting down trees and the decay kicks in you dont have to pick everyone up you just walk over them
With the timber mod its realy powerfull but a bit like "cheating".

Posted: Fri Aug 03, 2012 21:19
by VanessaE
This mod doesn't work the latest 0.4.2-rc1 release, or at least your latest update doesn't.

No errors are thrown and nothing visible happens; the world never appears after the initial node defs/media/etc screen.

Posted: Fri Aug 03, 2012 21:44
by Splizard
Nice mod, did not know this was possible! Only one problem, the server crashes when I leave the game:

Code: Select all

minetest/item_drop/init.lua:32: bad argument #2 to 'remove' (number expected, got userdata)

Posted: Sat Aug 04, 2012 09:21
by PilzAdam
VanessaE wrote:This mod doesn't work the latest 0.4.2-rc1 release, or at least your latest update doesn't.

No errors are thrown and nothing visible happens; the world never appears after the initial node defs/media/etc screen.
For me it works with latest Minetest (0.4.2-rc1) on kubuntu 11.10.

Posted: Sat Aug 04, 2012 09:21
by PilzAdam
Splizard wrote:Nice mod, did not know this was possible! Only one problem, the server crashes when I leave the game:

Code: Select all

minetest/item_drop/init.lua:32: bad argument #2 to 'remove' (number expected, got userdata)
Fixed that.

Posted: Sat Aug 04, 2012 09:46
by Clahymore
OMG!! I have been waiting for a mod like this. THANK YOU SO MUCH. It works fine with the latest 0.4.2 which is awesome.

Posted: Sat Aug 04, 2012 10:19
by Splizard
Sorry, another bug :(

Code: Select all

minetest/item_drop/init.lua:3: bad argument #1 to 'find' (string expected, got table)
This occurs when digging leaves (maybe since leaves have multiple node drop possibilities?).

Posted: Sat Aug 04, 2012 10:27
by Clahymore
Splizard wrote:Sorry, another bug :(

Code: Select all

minetest/item_drop/init.lua:3: bad argument #1 to 'find' (string expected, got table)
This occurs when digging leaves (maybe since leaves have multiple node drop possibilities?).
Yeah I just noticed that too. I made a new world and spawned on leaves then dug down and crashed my game :(

Posted: Sat Aug 04, 2012 12:30
by Clahymore
There is another bug with the moreores mod. When you dig it it crashes and says :
item_drop\init.lua:7: 'for' limit must be a number
?

Posted: Sat Aug 04, 2012 12:47
by PilzAdam
I will try to fix all the bugs but i am working on a secret mod now so it could take a while.
The next version will fix all the bugs. Please report new bugs here.

Posted: Sat Aug 04, 2012 15:18
by PilzAdam
All bugs fixed in version 3.

Posted: Sat Aug 04, 2012 15:25
by sfan5
Good!

Posted: Sat Aug 04, 2012 22:38
by Splizard
I dropped a bucket of lava with right click and this error occurred:

Code: Select all

minetest/item_drop/init.lua:90: attempt to index a nil value

Posted: Sun Aug 05, 2012 02:08
by Mallot1
PilzAdam wrote:
Mallot1 wrote:i dont know what minecraft like item/drop is please be more specific.
When you dig a block it dont appears in your inventory but it falls down as a item and you can pick it up by walking over it.
thx ill download it
aw man it crashs when i use my game use it 0.4.2

Posted: Sun Aug 05, 2012 03:08
by Spots
yea i'm getting issues too not stacking right i get max stacks of 69 (nice number though)and i mine tin and it crashes

Posted: Sun Aug 05, 2012 10:33
by PilzAdam
Splizard wrote:I dropped a bucket of lava with right click and this error occurred:

Code: Select all

minetest/item_drop/init.lua:90: attempt to index a nil value
Fixed. Ill upload it with version 4.

Posted: Sun Aug 05, 2012 10:34
by PilzAdam
Spots wrote:yea i'm getting issues too not stacking right i get max stacks of 69 (nice number though)and i mine tin and it crashes
It should be 64. Can you give me more information (Minetest version, os, item_drop version (more information => more help)).

Posted: Sun Aug 05, 2012 11:17
by Myu
When mining a lot, there's a stack issue as it seems

Here's the backtrace :

13:15:04: ERROR[main]: ServerError: LuaError: error: ...8331f0/bin/../games/minitest/mods/item_drop/init.lua:30: 'for' limit must be a number
13:15:04: ERROR[main]: stack traceback:

EDIT : oops, was using an old version under Minitest v5 Game, problem seems to be fixed when installing item_drop v3
but issue remains when mining ores from "moreores" mod