[Abandoned] [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
[Abandoned] [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Prevents digging trees by punching them.
Version: 0.2.0
Source code's license: EUPL v1.2 or later.
Textures and locale files' license: CC BY-SA 4.0 International or later.
Dependencies: default, farming (found in Minetest Game)
Supported: bonemeal, intllib, fallen_nodes, fallen_trees
Description:
Leaf nodes will drop sticks, dirt/cobble/stone/etc. nodes will drop rocks.
Wooden axe and wooden pick will be removed.
Stone tools can be crafted using sticks and rocks (or flints).
Rocks can be used to craft cobblestone nodes, recipe:
R = Rock
RRR
RRR
RRR
9 rocks give 1 cobblestone node.
These game mechanics have been ported from Voxelands.
Downloads:
Archives: .zip .tar.gz
Source code: Codeberg
Installation
Unzip the archive, rename the folder to hard_trees_redo and place it in
../minetest/mods/
If you only want this to be used in a single world, place it in
../minetest/worlds/WORLD_NAME/worldmods/
GNU+Linux - If you use a system-wide installation place it in
~/.minetest/mods/
For further information or help see:
https://wiki.minetest.net/Help:Installing_Mods
Version: 0.2.0
Source code's license: EUPL v1.2 or later.
Textures and locale files' license: CC BY-SA 4.0 International or later.
Dependencies: default, farming (found in Minetest Game)
Supported: bonemeal, intllib, fallen_nodes, fallen_trees
Description:
Leaf nodes will drop sticks, dirt/cobble/stone/etc. nodes will drop rocks.
Wooden axe and wooden pick will be removed.
Stone tools can be crafted using sticks and rocks (or flints).
Rocks can be used to craft cobblestone nodes, recipe:
R = Rock
RRR
RRR
RRR
9 rocks give 1 cobblestone node.
These game mechanics have been ported from Voxelands.
Downloads:
Archives: .zip .tar.gz
Source code: Codeberg
Installation
Unzip the archive, rename the folder to hard_trees_redo and place it in
../minetest/mods/
If you only want this to be used in a single world, place it in
../minetest/worlds/WORLD_NAME/worldmods/
GNU+Linux - If you use a system-wide installation place it in
~/.minetest/mods/
For further information or help see:
https://wiki.minetest.net/Help:Installing_Mods
Last edited by Hamlet on Fri Oct 02, 2020 17:07, edited 6 times in total.
My repositories: Codeberg.org | My ContentDB's page
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
Re: [Mod] Hard Trees Redo [0.1.1] [hard_trees_redo]
Notice: git repository back online.
My repositories: Codeberg.org | My ContentDB's page
Re: [Mod] Hard Trees Redo [0.1.1] [hard_trees_redo]
I'm not sure how to code it, but until you figure out how to add drops to nodes instead of overriding them, you might want to make a note that this is incompatible with TenPlus1's bonemeal. Only mention it because it seems that's a really popular mod in the server list I looked at. And it won't work with ours.
Someone added pebbles and sticks just lying on the ground (nature or forest_litter or something) that I always meant to port over with oddly_breakable_by_hand. That's a possible answer to making it compatible, if someone remembers what that was called.
Someone added pebbles and sticks just lying on the ground (nature or forest_litter or something) that I always meant to port over with oddly_breakable_by_hand. That's a possible answer to making it compatible, if someone remembers what that was called.
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
Re: [Mod] Hard Trees Redo [0.1.1] [hard_trees_redo]
As far as I know, once that you have defined and registered a node the only way to modify its behavior is to override it.ThorfinnS wrote:I'm not sure how to code it, but until you figure out how to add drops to nodes instead of overriding them, you might want to make a note that this is incompatible with TenPlus1's bonemeal. Only mention it because it seems that's a really popular mod in the server list I looked at. And it won't work with ours.
E.g.:
I register a stone that when dug does not drop anything, the node's definition will not have the field
Code: Select all
drops = {}
Code: Select all
drops = {"bob_mod:dollar"}
Anyway, thanks for the heads up: the conflicting code is here for BoneMeal and here for HardTreesRedo.
I will add support for BoneMeal's drop, maybe someone growing forests underground might use it.
Uh I can't remember either. I saw that in RealTest, but to be honest I don't like the look of it - I mean, it's realistic to find rocks laying on the ground (I'm thinking about rivers' sides, especially) but for some reason I can't get to like them.ThorfinnS wrote: Someone added pebbles and sticks just lying on the ground (nature or forest_litter or something) that I always meant to port over with oddly_breakable_by_hand. That's a possible answer to making it compatible, if someone remembers what that was called.
My repositories: Codeberg.org | My ContentDB's page
Re: [Mod] Hard Trees Redo [0.1.1] [hard_trees_redo]
Thorfinss: here's a little code snippet to insert item drops into a current node without overriding the existing ones:
viewtopic.php?f=9&t=9741&p=361200#p361200
viewtopic.php?f=9&t=9741&p=361200#p361200
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Released v0.2.0
Added:
- Support for Minetest Game v5.x new nodes.
- Support for Bonemeal.
Changed:
- License changed to EUPL v1.2.
- mod.conf set to follow Minetest v5.x specifics.
- Textures have been optimized with optipng.
- Code cleaning.
Removed:
- Support for Minetest Game v0.4.x
- ../doc/
Added:
- Support for Minetest Game v5.x new nodes.
- Support for Bonemeal.
Changed:
- License changed to EUPL v1.2.
- mod.conf set to follow Minetest v5.x specifics.
- Textures have been optimized with optipng.
- Code cleaning.
Removed:
- Support for Minetest Game v0.4.x
- ../doc/
My repositories: Codeberg.org | My ContentDB's page
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
I like your 5.x safe updated version.
Just an idea: Stones drop rock pieces still when you have metal or mese pickaxe/axe and don't need them anymore. Thus while mining you constantly have to get rid of them to avoid an overflow of your inventory. Maybe it's possible to stop dropping rocks if the player has a pickaxe tool in his inventory. I think sand and dirt is not digged too often. But digging stone is the main activity.
Just an idea: Stones drop rock pieces still when you have metal or mese pickaxe/axe and don't need them anymore. Thus while mining you constantly have to get rid of them to avoid an overflow of your inventory. Maybe it's possible to stop dropping rocks if the player has a pickaxe tool in his inventory. I think sand and dirt is not digged too often. But digging stone is the main activity.
CFS - still widely unknown
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Code: Select all
local picks = {"default:pick_steel", "default:pick_mese", "default:pick_diamond", "default:pick_obsidian"}
local inv = minetest.get_inventory({type="player", name="main"})
for i, p in ipairs(picks) do
if inv:contains_item(p)
--do not drop rocks => remove from drop-list
break
end
end
CFS - still widely unknown
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Remember that you can turn rocks into cobblestone nodes: placing 9 rocks in the crafting grid will give you 1 cobblestone.
99 rocks = 11 cobblestone nodes.
Or simply /pulverize while holding the stack.
I am not sure that preventing the rocks drop if the inventory contains a steel or better pick would be a good idea: following this reasoning, one might not want cobblestone drops as well - I have chests filled of cobblestone.
I'd rather change from the Craft Guide to the Unified Inventory, because the latter has a trash-can slot that can be used to delete unwanted items without using the /pulverize command; this would be useful both for rocks and cobblestone stacks.
What do you think?
99 rocks = 11 cobblestone nodes.
Or simply /pulverize while holding the stack.
I am not sure that preventing the rocks drop if the inventory contains a steel or better pick would be a good idea: following this reasoning, one might not want cobblestone drops as well - I have chests filled of cobblestone.
I'd rather change from the Craft Guide to the Unified Inventory, because the latter has a trash-can slot that can be used to delete unwanted items without using the /pulverize command; this would be useful both for rocks and cobblestone stacks.
What do you think?
My repositories: Codeberg.org | My ContentDB's page
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Yes, of course, these are possible ways. If you have a levelled up diamond pickaxe the inventory is just very fast full of rocks and cobblestone. From another point of view, rocks are even very realistic. Particularly concerning digging earth or mining. :)Remember that you can turn rocks into cobblestone nodes: placing 9 rocks in the crafting grid will give you 1 cobblestone.
99 rocks = 11 cobblestone nodes.
Or simply /pulverize while holding the stack.
I just thought about an elegant programmatically solution. The linked code snippet of TenPlus1 pointing out a different way of handling drops made me start thinking. I'm working on a more complex mod than bunkbed. I will need clay in the sense of loam for it and I want to run it together with darkage and hard_trees_redo. Darkage makes the default:clay to powder clay. So I just thought where can I get the loam from: As a dirt's drop would make sense. (Or somehow as an additional special sort of dirt. But that is far too complicated for me.)
I am not convinced of unified inventory. Since MT 5.x it shows items belonging into a creative mode inventory guide though you're in survival mode. And VanessaE has handed over maintaining the mod. sfinv based craftign guides are actively improved at the moment. This is just my impression. And I prefer the look and feel of sfinv. And backpacks. But I admit a trash slot can be an advantage. :)
CFS - still widely unknown
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Oh thanks for mentioning this: I've just discovered your bunkbed mod; some months ago I was pondering about adding a mod that added a campfire and a bedroll, for exploration or simply to skip nights in the game's early stages. Then I forgot about it, I'll keep an eye on your mod. :)Nordal wrote: I just thought about an elegant programmatically solution. The linked code snippet of TenPlus1 pointing out a different way of handling drops made me start thinking. I'm working on a more complex mod than bunkbed. I will need clay in the sense of loam for it and I want to run it together with darkage and hard_trees_redo. Darkage makes the default:clay to powder clay. So I just thought where can I get the loam from: As a dirt's drop would make sense. (Or somehow as an additional special sort of dirt. But that is far too complicated for me.)
Uh I wasn't aware of those issues; about the look and feel, I agree: I prefer sfinv over UI.Nordal wrote: I am not convinced of unified inventory. Since MT 5.x it shows items belonging into a creative mode inventory guide though you're in survival mode. And VanessaE has handed over maintaining the mod. sfinv based craftign guides are actively improved at the moment. This is just my impression. And I prefer the look and feel of sfinv. And backpacks. But I admit a trash slot can be an advantage. :)
About the trash slot, I did a little research and I've found that there are a couple of mods that add a trashcan item in-game, but no inventory slot. Except one coded by prestidigitator, which I used to make a mod: link.
I've tested it on Minetest Game, it works properly.
Unfortunately it does not work in Hamlet's Quest, no idea why: my knowledge of formspecs is zero.
If you have the time and the will, you could give it a look and see if it can be adapted for today's Minetest Game's inventory's look, and perhaps for Hamlet's Quest - I would surely add that utility!
My repositories: Codeberg.org | My ContentDB's page
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
It's been a while, so I wouldn't swear to it, but I think bell07 turned in a PR to add trash can to the smart_sfinv.
What is the creative/survival thing about UI? Do you mean that items that don't have a craft recipe are still listed?
What is the creative/survival thing about UI? Do you mean that items that don't have a craft recipe are still listed?
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Just downloaded and tried, no trashcan slot yet. However thanks for mentioning it, I'll keep an eye on it!ThorfinnS wrote:It's been a while, so I wouldn't swear to it, but I think bell07 turned in a PR to add trash can to the smart_sfinv.
My repositories: Codeberg.org | My ContentDB's page
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Found it. There are several, but this has the best looking ones I found, and I'm pretty sure the one I was thinking of.Hamlet wrote:Uh I can't remember either. I saw that in RealTest, but to be honest I don't like the look of it - I mean, it's realistic to find rocks laying on the ground (I'm thinking about rivers' sides, especially) but for some reason I can't get to like them.ThorfinnS wrote: Someone added pebbles and sticks just lying on the ground (nature or forest_litter or something) that I always meant to port over with oddly_breakable_by_hand. That's a possible answer to making it compatible, if someone remembers what that was called.
VanessaE's plantlife modpack, specifically components cavestuff and trunks.
https://gitlab.com/VanessaE/plantlife_modpack
viewtopic.php?f=11&t=3898
Just replace "cracky" and "choppy"with "dig_immediate" for the twigs and pebbles, and it operates pretty much how I'd like. Maybe the pebbles are too common to be a replacement for cobble, IMO, they are not common enough to be 9:1.
- Hamlet
- Member
- Posts: 766
- Joined: Sat Jul 29, 2017 21:09
- IRC: H4mlet
- In-game: Hamlet
- Location: Lombardy, Italy
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
Oh thanks for the info, I will check it for sure.ThorfinnS wrote: VanessaE's plantlife modpack, specifically components cavestuff and trunks.
https://gitlab.com/VanessaE/plantlife_modpack
viewtopic.php?f=11&t=3898
Just replace "cracky" and "choppy"with "dig_immediate" for the twigs and pebbles, and it operates pretty much how I'd like. Maybe the pebbles are too common to be a replacement for cobble, IMO, they are not common enough to be 9:1.
I did some tests with node decorations, that is, a blue cube to be randomly scattered on surface; I wanted to see if I could find a good perlin noise to implement surface rocks - my flat map got covered with blue nodes.
I guess I'll have to apply myself far better than what I did. :)
Speaking of pebbles... they could be good for a slingshot. No, surely not a cobble node for 9 pebbles, not even a gravel node I think.
I'd like rocks to be throw-able, to give players a cheap ranged weapon - well maybe not that good for a server, but for a local game it would be realistic.
My repositories: Codeberg.org | My ContentDB's page
Re: [Mod] Hard Trees Redo [0.2.0] [hard_trees_redo]
@ThorfinnS
Yes. If you have mob_animal of TenPlus1 installed UI lists every animal and every spawn-egg in it's inventory. No matter which mode (survival/creative).What is the creative/survival thing about UI? Do you mean that items that don't have a craft recipe are still listed?
CFS - still widely unknown
Who is online
Users browsing this forum: Mr. Rar and 34 guests