Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update backpacks mod source #179

Merged
merged 3 commits into from
Feb 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@
url = https://github.com/minetest-mods/wielded_light
[submodule "builder/mods_src/tools/backpacks"]
path = builder/mods_src/tools/backpacks
url = https://github.com/taikedz/everamzah-backpacks
url = https://codeberg.org/minenux/minetest-mod-backpacks.git
[submodule "builder/mods_src/tools/bonemeal"]
path = builder/mods_src/tools/bonemeal
url = https://github.com/minetest-mirrors/bonemeal.git
Expand Down
2 changes: 1 addition & 1 deletion builder/mods_src/tools/backpacks
Submodule backpacks updated from 7f617d to 22963b
4 changes: 2 additions & 2 deletions mod_sources.txt
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,8 @@ origin https://github.com/minetest-mods/wielded_light (fetch)
* 3dfc2623598e095954b0a97f6bac6da7096cdf10 Fix error when 'default' is disabled (#28)
Mod: player/wielded_light

origin https://github.com/taikedz/everamzah-backpacks (fetch)
* 7f617df442bfd75209ce64ffa46402c96a30ff4f removing rabbit_hide as it does not seem to be standard mobs_redo content
origin https://codeberg.org/minenux/minetest-mod-backpacks.git (fetch)
* 22963bf0740448eeac418eb3d21002a68a8b5861 update information and url.. licence
Mod: tools/backpacks

origin https://github.com/Lokrates/Biofuel.git (fetch)
Expand Down
83 changes: 80 additions & 3 deletions mods/tools/backpacks/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,82 @@
# Backpacks
# minetest mod Backpacks
========================

Backpacks allow you to clean up space in your inventory. They can be crafted by placing 8 wools of a same colour in a square around an empty craft grid centre.
Backpacks allow you to clean up space in your inventory.

![Screenshot](screenshot.png)
Information
-----------

This mod must be named `backpacks` it featured to player a
bag with shoulder straps that allow it to be carried on someone's back,
or just simple bags to carried payer items.

![screenshot.png](screenshot.png)

Tech information
----------------

Adds backpacks made of wool and leather, that can **store anything but themselves**
in an 16 slots inventory. The backpacks can only be accessed once they're placed.
Picking them up preserves their contents. They obey regular protection rules.
Development is at [https://git.minetest.io/minenux/minetest-mod-backpacks](https://git.minetest.io/minenux/minetest-mod-backpacks) codeberg is only for private developers,
if you want to contribute go to git.minetest.io as must be!

This mod started as a unification effors from forum original

https://forum.minetest.net/viewtopic.php?f=9&t=14579

The others mods similar are

* Improved https://github.com/jastevenson303/backpacks that is just
removed later in flavour of https://github.com/everamzah/backpacks
* Tenplus sfinv bags https://notabug.org/TenPlus1/sfinv_bags this only work in
recent engine versions and lost spirit of block, showing a so detailed rounded bags
* Exile one at https://codeberg.org/Mantar/Exile/src/branch/master/mods/backpacks that
provide the only feature to use modern api so inventory never get cleared and ambient influence

Unless all of those mods, this one is more simple and faster, and works with any version
of the engine since 0.4 version.

#### Dependencies

* default
* wool
* dye

Optional dependences:

* mobs

#### Nodes Tools

They can be crafted by placing 8 wools of a same colour in a square around an empty craft grid centre.
If you use any combination of wools, a brow backpack will be the result.

This backpacks mod provides a large featured basic foods production of backpacks:

| Node name | Description name |
| ------------------------------ | --------------------- |
| backpacks:backpack_wool_white | White Wool Backpack |
| backpacks:backpack_wool_grey | Grey Wool Backpack |
| backpacks:backpack_wool_black | Black Wool Backpack |
| backpacks:backpack_wool_red | REd Wool Backpack |
| backpacks:backpack_wool_yellow | Yellow Wool Backpack |
| backpacks:backpack_wool_green | Green Wool Backpack |
| backpacks:backpack_wool_cyan | Cyan Wool Backpack |
| backpacks:backpack_wool_blue | Blue Wool Backpack |
| backpacks:backpack_wool_brown | Brown Wool Backpack |
| backpacks:backpack_wool_violet | Violet Wool Backpack |

## LICENSE

Textures were provided originaly by James Stevenson but there is no hints about

Code were started by James Stevenson and later continue by Tai Kedzierski https://github.com/taikedz

License code is GPL3+ check [LICENSE.txt](LICENSE.txt) file. This fork
has one exception: You must put the url info in your copy and only allow this url to promotion:
[https://git.minetest.io/minenux/minetest-mod-backpacks](https://git.minetest.io/minenux/minetest-mod-backpacks)

Original code never get updates and get abandoned so we forked and **rethink the
license terms take into consideration the bad promotion that have real minetest spirits,
people only want to play and do not worry about constants changes and updates!**
1 change: 1 addition & 0 deletions mods/tools/backpacks/depends.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
default
dye
Lazerbeak12345 marked this conversation as resolved.
Show resolved Hide resolved
wool
mobs?
1 change: 1 addition & 0 deletions mods/tools/backpacks/description.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
BAGS mod for Minetest in real storage way usage
16 changes: 13 additions & 3 deletions mods/tools/backpacks/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ local function register_wool_backpack(colour,colourname)
{-0.25, -0.3125, -0.5, 0.25, 0.125, -0.4375},
}
},
groups = {dig_immediate = 3, oddly_diggable_by_hand = 3},
groups = {dig_immediate = 3, oddly_diggable_by_hand = 3, backpack = 1},
stack_max = 1,
on_construct = backpacks.on_construct,
after_place_node = backpacks.after_place_node,
Expand All @@ -108,8 +108,18 @@ local function register_wool_backpack(colour,colourname)
{"wool:"..colour, "wool:"..colour, "wool:"..colour},
}
})

end

minetest.register_craft({
Lazerbeak12345 marked this conversation as resolved.
Show resolved Hide resolved
output = "backpacks:backpack_wool_brown",
recipe = {
{"group:wool", "group:wool", "group:wool"},
{"group:wool", "", "group:wool"},
{"group:wool", "group:wool", "group:wool"},
}
})

local wooldyes = {
{code = "white", name = "White"},
{code = "grey", name = "Grey"},
Expand All @@ -131,7 +141,7 @@ local wooldyes = {
for _,colourdesc in pairs(wooldyes) do
register_wool_backpack(colourdesc.code,colourdesc.name)
end
minetest.register_alias("backpacks:backpack_wool", "backpacks:backpack_wool_white")
minetest.register_alias("backpacks:backpack_wool", "backpacks:backpack_wool_brown")

-- Leather backpack
minetest.register_node("backpacks:backpack_leather", {
Expand Down Expand Up @@ -161,7 +171,7 @@ minetest.register_node("backpacks:backpack_leather", {
{-0.25, -0.3125, -0.5, 0.25, 0.125, -0.4375},
}
},
groups = {dig_immediate = 3, oddly_diggable_by_hand = 3},
groups = {dig_immediate = 3, oddly_diggable_by_hand = 3, backpack = 1},
stack_max = 1,
on_construct = backpacks.on_construct,
after_place_node = backpacks.after_place_node,
Expand Down
3 changes: 3 additions & 0 deletions mods/tools/backpacks/mod.conf
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
name = backpacks
depends = default, wool, dye
optional_depends = mobs
description = BAGS mod for Minetest in real storage way usage
Binary file modified mods/tools/backpacks/textures/backpacks_backpack_back.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified mods/tools/backpacks/textures/backpacks_backpack_front.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified mods/tools/backpacks/textures/backpacks_backpack_sides.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified mods/tools/backpacks/textures/backpacks_backpack_topbottom.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified mods/tools/backpacks/textures/backpacks_leather.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.