Skip to content

Commit

Permalink
added acacia gum and plant wax datapacks
Browse files Browse the repository at this point in the history
  • Loading branch information
daenvil committed May 21, 2024
1 parent aac358b commit 6d4dc0a
Show file tree
Hide file tree
Showing 35 changed files with 665 additions and 0 deletions.
40 changes: 40 additions & 0 deletions acacia_gum/README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# Acacia Gum (v1.2, for Minecraft 1.20.5+)

This datapack adds the item "Acacia Gumball" (a retextured Slimeball), which is obtained by stripping acacia logs.

- This datapack was made by Daenvil, its official pages are:

- On PlanetMinecraft: https://www.planetminecraft.com/data-pack/acacia-gum-slime-from-stripping-acacias/
- On my website: https://daenvil.github.io/MCDatapacks/acacia_gum.html

- This version was published on the 21st of May 2024. Check the webpages above for possible updates.

## Installation

- Drop the datapack zip file inside the "datapacks" folder of your world folder (<your minecraft folder>/saves/<your world>/datapacks/).
- Drop the resourcepack zip file ("vegancraft-RP_v1.1.zip") inside the "resourcepacks" folder of your minecraft folder. If you don't have the resourcepack, download it from one of the webpages above.

## Features

Strip acacia logs/wood to get acacia gum. Use the acacia gum as you would use regular slime balls. You can see more info on this page: https://daenvil.github.io/MCDatapacks/acacia_gum.html

## Legal terms

You are allowed to:

- Download, use, and edit this datapack* for personal use.
- Use this datapack or variations of it in a Minecraft server.
- Publish audiovisual content that uses this datapack or variations of it (e.g. gameplay videos on online platforms), as long as you acknowledge me (Daenvil) as the author of this datapack and provide a link to its page on PlanetMinecraft (https://www.planetminecraft.com/data-pack/acacia-gum-slime-from-stripping-acacias/) or to its webpage (https://daenvil.github.io/MCDatapacks/acacia_gum.html).
- Share this datapack or variations of it privately (e.g. transferring the files to friends), as long as there is no financial profit involved, the files are not publicly available, and this text file is included with the files you share.

You are not allowed to:

- Publish this datapack or variations of it without explicit permission from me.

*For all legal purposes, "this datapack" refers to all the files (source code, images, and any other) that you downloaded along with this text file, and that are downloadable from its official pages listed above.

--

-Daenvil

https://daenvil.github.io/MCDatapacks/contact.html
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
give @s slime_ball[item_name="{\"translate\":\"dnv.acacia_gum.item.acacia_gum_ball\",\"fallback\":\"Acacia Gum\",\"italic\":false}",lore=["{\"text\":\"Daenvil's Acacia Gum\",\"color\":\"gold\",\"italic\":true}"],custom_model_data=9261005,custom_data={"dnv.vegan":true}]
30 changes: 30 additions & 0 deletions acacia_gum/data/dnv.acacia_gum/loot_tables/drop.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"type": "command",
"pools": [
{
"rolls": 1,
"entries": [
{
"type": "item",
"weight": 1,
"functions": [
{
"function": "set_components",
"components": {
"item_name": "{\"translate\":\"dnv.acacia_gum.item.acacia_gum_ball\",\"fallback\":\"Acacia Gum\",\"italic\":false}",
"lore": [
"{\"text\":\"Daenvil's Acacia Gum\",\"color\":\"gold\",\"italic\":true}"
],
"custom_model_data": 9261005,
"custom_data": {
"dnv.vegan": true
}
}
}
],
"name": "slime_ball"
}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"condition": "random_chance",
"chance": 0.25
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"condition": "random_chance",
"chance": 0.25
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"condition": "random_chance",
"chance": 0.5
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"condition": "random_chance",
"chance": 0.75
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"condition": "any_of",
"terms": [
{
"condition": "entity_properties",
"entity": "this",
"predicate": {
"slots": {
"weapon.mainhand": {
"items": "#axes",
"predicates": {
"enchantments": [
{
"enchantment": "minecraft:fortune",
"levels": 1
}
]
}
}
}
}
},
{
"condition": "entity_properties",
"entity": "this",
"predicate": {
"slots": {
"weapon.offhand": {
"items": "#axes",
"predicates": {
"enchantments": [
{
"enchantment": "minecraft:fortune",
"levels": 1
}
]
}
}
}
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"condition": "any_of",
"terms": [
{
"condition": "entity_properties",
"entity": "this",
"predicate": {
"slots": {
"weapon.mainhand": {
"items": "#axes",
"predicates": {
"enchantments": [
{
"enchantment": "minecraft:fortune",
"levels": 2
}
]
}
}
}
}
},
{
"condition": "entity_properties",
"entity": "this",
"predicate": {
"slots": {
"weapon.offhand": {
"items": "#axes",
"predicates": {
"enchantments": [
{
"enchantment": "minecraft:fortune",
"levels": 2
}
]
}
}
}
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"condition": "any_of",
"terms": [
{
"condition": "entity_properties",
"entity": "this",
"predicate": {
"slots": {
"weapon.mainhand": {
"items": "#axes",
"predicates": {
"enchantments": [
{
"enchantment": "minecraft:fortune",
"levels": 3
}
]
}
}
}
}
},
{
"condition": "entity_properties",
"entity": "this",
"predicate": {
"slots": {
"weapon.offhand": {
"items": "#axes",
"predicates": {
"enchantments": [
{
"enchantment": "minecraft:fortune",
"levels": 3
}
]
}
}
}
}
}
]
}
26 changes: 26 additions & 0 deletions acacia_gum/data/global/advancements/dnv.acacia_gum.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"parent": "global:dnv.vegancraft",
"display": {
"title": {
"text": "Acacia Gum",
"italic": false
},
"description": {
"text": "Daenvil's Acacia Gum 1.2 (for MC1.20.5+)",
"italic": false
},
"icon": {
"id": "slime_ball",
"components": {
"custom_model_data": 9261005
}
},
"show_toast": false,
"announce_to_chat": false
},
"criteria": {
"tick": {
"trigger": "tick"
}
}
}
23 changes: 23 additions & 0 deletions acacia_gum/data/global/advancements/dnv.vegancraft.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"parent": "global:root",
"display": {
"title": {
"text": "Vegancraft",
"italic": false
},
"description": {
"text": "Daenvil's Vegancraft datapacks",
"italic": false
},
"icon": {
"id": "kelp"
},
"show_toast": false,
"announce_to_chat": false
},
"criteria": {
"tick": {
"trigger": "tick"
}
}
}
20 changes: 20 additions & 0 deletions acacia_gum/data/global/advancements/root.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"display": {
"title": {
"text": "Installed Datapacks",
"italic": false
},
"description": "",
"icon": {
"id": "knowledge_book"
},
"background": "minecraft:textures/block/gray_concrete.png",
"show_toast": false,
"announce_to_chat": false
},
"criteria": {
"tick": {
"trigger": "tick"
}
}
}
5 changes: 5 additions & 0 deletions acacia_gum/data/minecraft/tags/functions/load.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"values": [
"zz.dnv.vegancraft:load_acacia_gum"
]
}
6 changes: 6 additions & 0 deletions acacia_gum/data/zz.dnv.core/tags/blocks/acacia_bark.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"values": [
"acacia_log",
"acacia_wood"
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"criteria": {
"#axes_used_on_#zz.dnv.core:acacia_bark": {
"trigger": "item_used_on_block",
"conditions": {
"location": [
{
"condition": "minecraft:match_tool",
"predicate": {
"items": "#axes"
}
},
{
"condition": "minecraft:location_check",
"predicate": {
"block": {
"blocks": "#zz.dnv.core:acacia_bark"
}
}
}
]
}
}
},
"rewards": {
"function": "zz.dnv.vegancraft:slots/on_used_axe_on_acacia_bark"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
execute store result score @s dnv.acacia_gum.raycast_range run attribute @s player.block_interaction_range get -10
scoreboard players operation @s dnv.acacia_gum.raycast_range_doubled = @s dnv.acacia_gum.raycast_range
scoreboard players operation @s dnv.acacia_gum.raycast_range_doubled *= #dnv dnv.2
scoreboard players set @s dnv.acacia_gum.found_acacia 0
execute anchored eyes positioned ^ ^ ^ anchored feet run function zz.dnv.vegancraft:find_acacia_bark_line
execute if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range anchored eyes positioned ^ ^ ^1 anchored feet run function zz.dnv.vegancraft:find_acacia_bark_wide
execute if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range_doubled run function zz.dnv.vegancraft:summon_acacia_gum_ball
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
execute if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia matches ..0 if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range run scoreboard players remove @s dnv.acacia_gum.found_acacia 1
execute if score @s dnv.acacia_gum.found_acacia matches ..0 if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range positioned ^ ^ ^.1 run function zz.dnv.vegancraft:find_acacia_bark_line
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
execute if block ^1 ^ ^ #zz.dnv.core:acacia_bark positioned ^1 ^ ^ run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^-1 ^ ^ if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^ ^1 ^ if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^ ^-1 ^ if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^1 ^1 ^ if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^1 ^-1 ^ if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^-1 ^1 ^ if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^-1 ^-1 ^ if block ~ ~ ~ #zz.dnv.core:acacia_bark run function zz.dnv.vegancraft:summon_acacia_gum_ball
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range run scoreboard players remove @s dnv.acacia_gum.found_acacia 1
execute if score @s dnv.acacia_gum.found_acacia >= @s dnv.acacia_gum.raycast_range_doubled if score @s dnv.acacia_gum.found_acacia < @s dnv.acacia_gum.raycast_range positioned ^ ^ ^.1 run function zz.dnv.vegancraft:find_acacia_bark_wide
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
scoreboard objectives add dnv.acacia_gum.found_acacia dummy
scoreboard objectives add dnv.acacia_gum.n_drops dummy
scoreboard objectives add dnv.acacia_gum.raycast_range dummy
scoreboard objectives add dnv.acacia_gum.raycast_range_doubled dummy
scoreboard objectives add dnv.2 dummy
scoreboard players set #dnv dnv.2 2
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
advancement revoke @s only zz.dnv.vegancraft:triggers/used_axe_on_acacia_bark
scoreboard players set @s dnv.acacia_gum.n_drops 0
execute if predicate dnv.acacia_gum:extra_drop_chance_fortune_3 if predicate dnv.acacia_gum:holding_axe_fortune_3 run scoreboard players set @s dnv.acacia_gum.n_drops 1
execute unless score @s dnv.acacia_gum.n_drops matches 1 if predicate dnv.acacia_gum:extra_drop_chance_fortune_2 if predicate dnv.acacia_gum:holding_axe_fortune_2 run scoreboard players set @s dnv.acacia_gum.n_drops 1
execute unless score @s dnv.acacia_gum.n_drops matches 1 if predicate dnv.acacia_gum:extra_drop_chance_fortune_1 if predicate dnv.acacia_gum:holding_axe_fortune_1 run scoreboard players set @s dnv.acacia_gum.n_drops 1
execute if predicate dnv.acacia_gum:drop_chance_no_fortune run scoreboard players add @s dnv.acacia_gum.n_drops 1
execute if score @s dnv.acacia_gum.n_drops matches 1.. run function zz.dnv.vegancraft:find_acacia_bark
Loading

0 comments on commit 6d4dc0a

Please sign in to comment.