Node Dig Group Levels with Times and Tool Dig Group Levels

User avatar
SegFault22
Member
 
Posts: 870
Joined: Mon May 21, 2012 03:17

Node Dig Group Levels with Times and Tool Dig Group Levels

by SegFault22 » Fri Dec 02, 2016 17:04

I've thought for quite some time that it would be useful to set the dig group level time of a node by its own properties, instead of the tool being used to dig it. This would be particularly useful if for example you want a tool to be able to dig two different nodes which are at the same dig group level, but one node is made of a material that is "heavier" and thus takes slightly longer to dig (dirt thicker than sand).

As far as I can tell, this would require a partial restructuring of the system for tools and the system for nodes, such that the nodes have their dig group level times defined in the registry entry and the tools have just the dig group levels defined. It would probably break old mods if it is implemented directly without any form of backwards-compatibility, but surely there is a simple way to enable mods to use the "old method" (when the dig group level times are defined for a tool registry entry, "auto-fill" each dig group level time to each node which is registered by the mod; if node registry entries without dig group level times are processed before a tool registry entry with the corresponding dig group levels from the same mod, processing their dig group level times is postponed until a tool registry entry is processed or the mod is finished loading; if no tools are defined for dig group levels used in a mod, a set of default values is used instead, corresponding to the properties of default tools before the change).

Is there anything I am missing, which would make this not possible to implement or complicated beyond reason?
 

User avatar
MineYoshi
Member
 
Posts: 4267
Joined: Wed Jul 08, 2015 13:20
GitHub: MineYosh
IRC: MineYoshi
In-game: Kirby_Retro

Re: Node Dig Group Levels with Times and Tool Dig Group Leve

by MineYoshi » Fri Dec 02, 2016 19:37

I like your idea. Bñut i have a question:
-Every node has different "heaviness", but when i have a better pick, will the pick mine better the nodes than a less powerful pick in a consistent speed upgrade?
Also the tools will have different "performance" depending in what tools are and of what made?
People talk about freedom of speech, so i'll say that God exists.
Open your eyes!! See The big unicorn conspiracy.!! :D The government has been lying to us about unicorns!!
"I've learned there are three things you don't discuss with people: religion, politics and the Great Pumpkin" - Linus Van Pelt
I'm the Officially 1st ABJist in the world ( ͡° ͜ʖ ͡°)
 

User avatar
SegFault22
Member
 
Posts: 870
Joined: Mon May 21, 2012 03:17

Re: Node Dig Group Levels with Times and Tool Dig Group Leve

by SegFault22 » Sat Dec 03, 2016 01:38

The tools' ability to mine a node would depend on its dig level number for that group - for example, cracky 3 is stuff like stone and cobble, and all tools which can mine one of them can also mine the other. The mining speed would be independent of the dig level. If for example you make a coarse gravel/pebble block which falls like sand or gravel and it is crumbly=3 like dirt and sand, it could be mined with any shovel capable of that level, but its dig time could be longer than that of sand or dirt because it is simply more difficult to dig and not damaging the tool any more than the other stuff.

This would probably work best if the dig group level times need only to be specified for the lowest level which can mine the tool, and all higher levels would multiply the dig speed (divide dig time) based on the highest level of the tool; this would also make it possible to only need specifying the highest level of each group which a tool can mine, and all lower levels be calculated automatically. This would be much simpler than what is used now, since you wouldn't have to figure out how to balance the dig group level times for all levels of all groups assigned to every tool - but we should still be able to specify the dig time for more than one level of the same dig group assigned to a node, so that developers can fine-tune the dig times for higher levels of the automatically-calculated value(s) are not sufficiently balanced (dig times may feel too fast or too slow for some people).

It would also cause all tools with the same maximum dig level of some group to dig a node at the same speed, which makes some sense as the dig time relates to how difficult it is to dig a node and the dig level relates to what materials are strong enough to break a node.
 


Return to Minetest Features

Who is online

Users browsing this forum: No registered users and 43 guests

cron