[mod] Full Inventory [0.2] [fullinventory_0gb_us]

Post Reply
User avatar
0gb.us
Member
Posts: 841
Joined: Sun Sep 16, 2012 01:55
Location: 0gb.us:30000
Contact:

[mod] Full Inventory [0.2] [fullinventory_0gb_us]

by 0gb.us » Post

Development of fullinventory_0gb_us as a single plugin will no longer continue. If anyone is still interested in this, it is still being developed as part of 0gb.us_game, the game used at 0gb.us:30000.

Topic: http://forum.minetest.net/viewtopic.php?id=3808
Github: https://github.com/0gb-us/0gb.us_game/t ... gb.us_game

Although, there's not much left to develop. If you need a bug fix, let me know, but I can't really add to this. support for this plugin will be dropped upon the release of Minetest 0.4.5. Changes to the built-in scripts made by PilzAdam make this thing unnecessary. (Yay!)


[mod] Full Inventory [0.2] [fullinventory_0gb_us]

Normally, if you continue mining when your inventory is full, the newly acquired items are lost. This plugin fixes that. Instead, mining is disabled when something won't fit in your inventory, and a warning message is displayed. At that time, the player can drop any unnecessary items into a chest, and continue mining. Sorry for the short description, but this is a short script, and it's effect is pretty straightforward.

UPDATE: The new version does the same thing, but ALSO applies the effect to dropped items. No more picking up items your friend gave you, only to realize that your inventory was full!

UPDATE: The new version is now compatible with the pistons from mesecons, the Tunnel Boring Machine (tbm plugin), and my fork of PilzAdam's rewrite of bones.

Code license: GNU LGPL version 2
Image license: No images included.

Dependencies: none

New version: http://0gb.us/minetest/download.php?plu ... 0gb_us-0.2 (fixed compatibility)

Old versions:
http://0gb.us/minetest/download.php?plu ... 0gb_us-0.1 (added awareness of dropped items)
http://0gb.us/minetest/download.php?plu ... 0gb_us-0.0 (original)
Last edited by 0gb.us on Sat Feb 23, 2013 19:34, edited 1 time in total.

User avatar
Chinchow
Member
Posts: 684
Joined: Tue Sep 18, 2012 21:37

by Chinchow » Post

Great I hate it when I mine and lose the stuff I mine will try
Sometimes, it's harder to think up a mod than it is to create it.
Mods: Orichalcum Stonebricks Extra Chests

User avatar
Aqua
Member
Posts: 641
Joined: Wed Aug 22, 2012 09:11
Location: Sydney~Singapore
Contact:

by Aqua » Post

Amazing=D
Hi there ^.~

User avatar
0gb.us
Member
Posts: 841
Joined: Sun Sep 16, 2012 01:55
Location: 0gb.us:30000
Contact:

by 0gb.us » Post

This is quite possiblely my favourite plugin I built. So simple, yet very helpful.

Unfortunately, development has come to a halt, because of that simplicity. Quite frankly, there is nothing left to do. If you find a bug, post it, but there really isn't much that could go wrong.

Admittedly, there is a small issue where if a node has multiple sets of drops (for example, mining leaves could give you a sapling sometimes, and a leaf block other times), then this plugin could theoretically guess the wrong one, check that you had room for it, and then the game could try to add the OTHER to your inventory. Unless implemented as a patch, or implemented in a way that could potentially break compatibility with other plugins, there is nothing I can do about that. In the default game though, this only applies to leaf blocks.

Please note that this only applies to nodes that don't always drop the same thing. If it always drops the same set of things, no matter how many types of things it drops at once, it will work as intended.

The new (and likely final) version applies the effect to dropped items as well as mined nodes. Unlike mined nodes, the content of a dropped item is already decided, so it will never be lost.

EDIT: Fixed grammar
Last edited by 0gb.us on Thu Dec 20, 2012 18:55, edited 1 time in total.

User avatar
Aqua
Member
Posts: 641
Joined: Wed Aug 22, 2012 09:11
Location: Sydney~Singapore
Contact:

by Aqua » Post

This should be in the default game =D
Hi there ^.~

User avatar
0gb.us
Member
Posts: 841
Joined: Sun Sep 16, 2012 01:55
Location: 0gb.us:30000
Contact:

by 0gb.us » Post

If it were in the default game, it wouldn't have the small flaw that it theoretically has right now. It could be implemented better if it was in the built-in scripts, and not used as a plugin. But it seems that some people don't like what this does, so it probably will not be added to the main game. Too bad.

User avatar
Casimir
Member
Posts: 1207
Joined: Fri Aug 03, 2012 16:59
GitHub: CasimirKaPazi

by Casimir » Post

I like it.

User avatar
0gb.us
Member
Posts: 841
Joined: Sun Sep 16, 2012 01:55
Location: 0gb.us:30000
Contact:

by 0gb.us » Post

I thought there was nothing left to fix, but I was wrong. Fixed an error where this plugin assumes that anybody that digs MUST be a player. Non-player diggers are now ignored, restoring compatibility with plugins that make use of node_dig().

User avatar
Casimir
Member
Posts: 1207
Joined: Fri Aug 03, 2012 16:59
GitHub: CasimirKaPazi

by Casimir » Post

Have you already done a pull request?

User avatar
0gb.us
Member
Posts: 841
Joined: Sun Sep 16, 2012 01:55
Location: 0gb.us:30000
Contact:

by 0gb.us » Post

I have, however, PilzAdam doesn't like my fixes. He'd rather keep the problems in his version, I guess.

I'm currently trying to rework the code some more, to make it work for both of us, but haven't made much progress.
Last edited by 0gb.us on Fri Jan 04, 2013 20:39, edited 1 time in total.

User avatar
0gb.us
Member
Posts: 841
Joined: Sun Sep 16, 2012 01:55
Location: 0gb.us:30000
Contact:

by 0gb.us » Post

Development of fullinventory_0gb_us as a single plugin will no longer continue. If anyone is still interested in this, it is still being developed as part of 0gb.us_game, the game used at 0gb.us:30000.

Topic: http://forum.minetest.net/viewtopic.php?id=3808
Github: https://github.com/0gb-us/0gb.us_game/t ... gb.us_game

Although, there's not much left to develop. If you need a bug fix, let me know, but I can't really add to this. support for this plugin will be dropped upon the release of Minetest 0.4.5. Changes to the built-in scripts made by PilzAdam make this thing unnecessary. (Yay!)

Post Reply

Who is online

Users browsing this forum: No registered users and 11 guests