Questions tagged [minecraft-data-packs]

Used for questions about server-side packs that add or change recipes, advancements, structures and more in Minecraft Java edition. Always use with the [minecraft-java-edition] tag.

Filter by
Sorted by
Tagged with
2 votes
1 answer
28 views

Can mobs be equipped with armour based on drops from a loot table?

I am making a RPG/Dungeon Crawler datapack and I want to procedurally make dungeons throughout the world. I have somewhat figured out how to make the dungeons, but I want the monsters to be random (e....
user avatar
7 votes
1 answer
915 views

What loot tables have mending?

I am looking for a list of chests that are able to have mending (either on an enchanted book or a "treasure" item). I remember seeing a list on the wiki a long time ago but it does not seem ...
user avatar
  • 961
0 votes
0 answers
20 views

Detect when a player has 'none' score [duplicate]

When a scoreboard is set, initially all players do not have a value set for that score, similar to null in programming. How would I detect it in execute if score? I can't just use matches 0 because ...
user avatar
1 vote
1 answer
50 views

Adding custom structure to replace ancient_city_center

I would like to have a custom structure I made replace the city_center structure of an ancient city, except when I do that, cities do not generate at all. To make sure it was working, I replaced the ...
user avatar
  • 961
1 vote
1 answer
62 views

Is it possible to add components/bars to the HUD Minecraft Java 1.19.x

I am trying to make a survival datapack that would require you to drink water. Is it possible to add an element to the HUD to indicate how much water you need based on a scoreboard value? I did some ...
user avatar
0 votes
0 answers
158 views

Minecraft Error Exit Code 6 Problematic Error [duplicate]

I recently made a post and I was told that it was a Problematic error, but still don't get it. I run a MacBook Pro Moneterey and the Chip is an Apple M1. (don't know if needed) And I have tried all ...
user avatar
0 votes
0 answers
22 views

How do I summon a fireball that is immediately moving in the direction I'm looking? [duplicate]

I'm trying to make a mage staff and I have right-click detection all figured out but I need to summon something that moves in the direction I'm facing. I was originally using a fireball because the ...
user avatar
0 votes
2 answers
38 views

How to detect if an item is dropped near an armor stand?

I'm trying to make a sort of shrine system where a player can drop a set number of items, say five gold ingots near a shrine, which is a block with an armor stand inside of it, and be given a ...
user avatar
  • 101
1 vote
1 answer
49 views

How to print the name of the block under me in Minecraft?

If wanted to make a data pack that takes the block under me and then says: "The block under me is [block]". How would I do that? If this was like a mix between Java and Minecraft then it ...
user avatar
1 vote
0 answers
70 views

Summon/data merge villager with Explorer Map trade

As the title states, I would like to add an explorer map to a summon villager command but nothing seems to be working. More specifically, I would like to append that trade to an existing villager. Is ...
user avatar
  • 961
2 votes
1 answer
148 views

Is it possible to create a custom ore and add it to world generation with a Datapack?

As the title suggests, I am wanting to add custom ores to the game (I.E. new gemstones like ruby, sapphire, topaz, etc), but I have no clue how to control world generation to add such a thing. I tried ...
user avatar
0 votes
1 answer
35 views

Incrementing attributes in Minecraft

I want to figure out how to increment a player's health without writing 225 lines of Datapack code. I cannot find any way to do this. I've tried : execute at @a run execute unless score @p custHealth ...
user avatar
  • 37
3 votes
2 answers
227 views

Proper path to modify villager anger?

I would like to make villagers angry on command. I assume I need to use /data modify, but I do not know the proper <targetPath>. I have the following so far: execute as @e[type=villager] run ...
user avatar
  • 961
1 vote
0 answers
126 views

Giving an advancement on crafting a recipe

I have a datapack and in the datapack is a custom crafting recipe. In the advancements folder, I have created an advancement which should trigger when I craft the recipe. However if I craft the item I ...
user avatar
1 vote
0 answers
219 views

Issues with overwriting crafting recipe in Minecraft Data Pack

I'm new to making resource packs for Minecraft Java and have decided to try to create some custom crafting. I've tried to change the recipe for black dye, requiring you to craft it with a diamond. I ...
user avatar
2 votes
0 answers
164 views

Testing for if an item entity has an ID matching a list of item names

I am making a datapack that uses copper as a fuel, however part of that means that I need to be able to test an item when it is on the ground to see if it is one of the 37 copper items. I have already ...
user avatar
  • 101
3 votes
1 answer
116 views

Tag for items not burnable in lava (like netherite)

Nice and simple. What is the tag for items to be not burnable in lava, like netherite ingots? Or how would I make other items like obsidian not burn?
user avatar
  • 961
0 votes
1 answer
125 views

Command is running weirdly from load.json (datapack)

Could someone help me? I am thoroughly confused. I have a command in my datapack that is executed from load.json function: execute unless entity @e [type=armor_stand,name=team_lives,scores={...
user avatar
4 votes
1 answer
146 views

What structures can be placed with a structure block?

I would like to edit/replace the swamp hut and mineshafts, but I am not sure what the namespace/path is. So does anyone know of a list of the structures that can be placed with the structure block and ...
user avatar
  • 961
0 votes
2 answers
106 views

Storing a player's location and teleporting the player back to it later in Java Minecraft

I'm looking for a way to store a player's current location (probably in the scoreboard as separate X, Y and Z) and teleport the player to that location later. I'm not completely familiar with the ...
user avatar
  • 193
0 votes
1 answer
216 views

Why is my datapack so laggy?

https://www.planetminecraft.com/data-pack/aceplante-s-rl-megapack-for-1-17/ For every single function I have added so far, I have been careful to add tag checks. For example, if I want to replace the ...
user avatar
  • 961
2 votes
1 answer
85 views

Execute as mobs wearing any type of armor?

I am making a datapack that adds weight (slight movement speed penalty) to armor using attributes. I got it working for players using the command: execute as @e[type=player,nbt={Inventory:[{Slot:100b}]...
user avatar
  • 961
1 vote
1 answer
42 views

Tall flower loot table issue

Since tall flowers are considered two blocks, both halves trigger a loot table when broken. In vanilla, the game gets around this by having the loot tables check (and only drop the flower) if it is a ...
user avatar
  • 961
0 votes
1 answer
71 views

Teleporting to the Nether with entities

I'm making a datapack and I want to make it so that when people spawn on a certain block you teleport to the same block in the Nether. However, nothing happens. This is my code: execute as @e[tag=...
user avatar
  • 37
4 votes
1 answer
157 views

How to use predicates inside of advancements?

I'm trying to use predicates inside of advancement triggers. According to the wiki I should be abled to use the player tag, but I couldn't figure out, how the syntax works exactly. player: The ...
user avatar
0 votes
1 answer
131 views

How to detect if someone is hit by something with a custom model data?

I'm trying to make a data pack with custom items in it but I can't figure out how to detect if someone is hit by an item with a Custom Model Data. I have tried using an advancement, but it seems to ...
user avatar
1 vote
2 answers
103 views

"match_tool" enchant check for entity loot table?

I would like to have shulkers be able to drop a second shell IF and ONLY IF they are killed with looting 4. I cannot seem to figure out how to do that. The only thing I can think of is having a "...
user avatar
  • 961
2 votes
2 answers
132 views

Loot table based on NBT data

So I would like to have phantoms drop extra membranes the larger they are, except it seems like the min/max is ignored? When I kill regular phantoms with looting 3 for example I usually get 4 ...
user avatar
  • 961
0 votes
0 answers
32 views

How can I track that the player has placed a block and cancel the damage while on it?

I have this code in datapack: execute as @a at @s if block ~ ~-0.05 ~ minecraft:grass_block run effect give @s minecraft:instant_damage 1 1 true execute as @a at @s if block ~ ~-0.05 ~ minecraft:dirt ...
user avatar
0 votes
1 answer
132 views

How can i find anvil GUI nbt?

So i'm trying to to make a datapack, where you can enchant blocks with enchantments on an anvil in survival. I've tried getting player's data, block's data, but i can't find where the anvil GUI nbt is ...
user avatar
  • 155
0 votes
0 answers
60 views

How to move the contents of a chest to a Bundle using commands?

I'm currently trying to move the contents of a chest into a bundle (being held by a placeholder armor stand) but the most it would do is copy the last item in the chest (that is not minecraft:air) ...
user avatar
  • 1
0 votes
1 answer
55 views

How to Group undead mobs in a datapack?

I have this in my datapack, in a JSON file: { "values": [ "minecraft:drowned", "minecraft:husk", "minecraft:phantom", "minecraft:skeleton&...
user avatar
2 votes
0 answers
160 views

Can a custom dimension overwrite the overworld?

I am trying to learn how to use datapacks to affect world generation. I currently have a datapack with the following files: \pack.mcmeta: { "pack": { "pack_format": 8, &...
user avatar
2 votes
1 answer
75 views

Help with loading far away random chunks using commands

I'm making a working Tardis in Minecraft using datapack dimensions. Part of that is the ability to send the Tardis exterior anywhere in the world (And eventually in the Nether and End too). The /...
user avatar
  • 101
2 votes
1 answer
49 views

Error: Objectives cannot be longer than 16 characters

I make use of scoreboards to keep track of variables. However, this error popped up on the console when I tried reloading my datapack: Failed to load function terraria:wands/rod_of_discord/use java....
user avatar
1 vote
1 answer
213 views

Teleport to Scaled Coordinates?

I am working on a datapack and would like the give the end dimension a coordinate scale like the nether (so it can be used for fast travel). So I set the coordinate scale to 16 in the json file and it ...
user avatar
  • 961
0 votes
1 answer
42 views

How to make bats giving poison effect to nearby players?

Bats don't do anything, and I'm thinking of making a datapack, so that when a bat gets close to a player, it will "bite" them, giving them a poison effect. How would I do this?
user avatar
1 vote
1 answer
628 views

Add armor attributes with /item modify- 1.17 datapack issue

I am trying to modify the armor a certain entity is wearing (based on material) by adding a very slight movement speed decrease, which I should be able to do with attributes. I have the entity tagged ...
user avatar
  • 961
1 vote
1 answer
324 views

Minecraft: Using block states within datapack tags

I have a datapack which uses a stonecutter to automatically break whatever block is above it, however currently it is always on, meaning the only way to stop it is to break the actual block. Having ...
user avatar
  • 101
0 votes
1 answer
34 views

Why are my commands applying to everyone instead of just the person with the tag?

The commands are applying to everyone in the server (every entity on the first one) and not just the person with the tag, these are the commands in the tick.mcfunction file: execute as @e at @e if ...
user avatar
2 votes
1 answer
92 views

Minecraft Data pack bug, mobs are just floating items

I play on a Mac, I'm not sure if that matters since it worked every time up to this point. This is what's wrong, for example. I have installed a random datapack, a snow golem with a melon head instead ...
user avatar
0 votes
1 answer
78 views

Simulate TNT and fireballs

For a bedwars Minigame in vanilla I need TNT and fireballs, but they should only break certain blocks and deal damage. For the TNT I have this: execute as @e[type=tnt,nbt={Fuse:1s}] at @a run function ...
user avatar
6 votes
1 answer
174 views

Can I create a custom biome with no floor for my datapack?

I've been looking into custom world generation recently and I found out that you can create custom biomes and have them generate in the world. I was wondering if it was at all possible to use this to ...
user avatar
  • 469
1 vote
0 answers
99 views

Custom recipes with item with custom NBT as output [duplicate]

I'm trying to make custom recipes for a datapack and have found out how, but not how to change the output to anything but a basic item. I want to output a carrot_on_a_stick with the custom NBT data of ...
user avatar
3 votes
0 answers
59 views

How would I test if my custom dimension exists?

I'm making a datapack that relies on a custom dimension. If the dimension hasn't loaded in, it will break things. When you add the datapack to a pre-existing world, then the dimension won't load until ...
user avatar
1 vote
1 answer
345 views

How do I make it that /trigger will only execute a command once?

So I am making a datapack for custom enchantments. I want to make it where every time I use /trigger , then the command will be executed once. However, at the same time the objective value used in /...
user avatar
7 votes
1 answer
246 views

Check players permission-level

I am currently working on a minecraft map for realms, and was wondering if there is any way to check a players op/permission level. In a minigame, no one has operator permissions except the owner who ...
user avatar
  • 71
1 vote
1 answer
53 views

"vanilla:entities" not working in Minecraft loot table

I have this loot table in my datapack: { "type": "minecraft:entity", "pools": [ { "rolls": 1, "entries": [ ...
user avatar
0 votes
2 answers
438 views

Minecraft 1.17 how to create custom coloured potion texture pack

I would like to design a texture pack with custom more distinguishable potion colours for each potion type. How do I go about doing this? I've been able to unpack the .jar file, find the \assets\...
user avatar
1 vote
1 answer
234 views

Why is my loot table not showing up in the /loot command?

I've created a loot table[1] and I'm having issues using it with the loot command: loot insert ~ ~ ~ loot minecraft:op Executing the command above drops zero items. The JSON for the loot table is: { ...
user avatar