Making function tags iterable would allow more performant function calling when using tags. Instead of having to run all the functions in the tag at once, they could call any number of functions whenever they felt like it, without having to know the exact names of the functions, instead of calling all of them every time. This also makes it easy for other datapacks to extend functionality without affecting game performance.
Example Uses:
- Custom crafting - Only going through 1 recipe per tick until a match is found or it runs out of recipes.
- Random function calls - Every n ticks for an entity, call a random function from the list of functions.
- Function call breaking - Run 1 function out of the list until some condition is met, the stop iterating.
Proposed additions to the /function command:
- /function size #functionTag
- /function call #functionTag <entity> <objective>
Please sign in to leave a comment.
0 Comments