#Items General
1 messages ยท Page 9 of 1
okay okay, thank you I will try that
Here
{
"rolls": {
"min": 0,
"max": 1
},
"entries": [
{
"type": "item",
"name": "minecraft:goat_horn",
"functions": [
{
"function": "set_data",
"data": {
"min": 0,
"max": 3
}
}
]
}
]
From pillager outpost loot table
ahhh I seeee
thank you I was literally just figuring it out too lol
I guess I just gotta find the number that corresponds to the variant I want
This is for random data; for a specific data value, you can use
{
"function": "set_data",
"data": 30
}.
I found it
{
"function": "set_data",
"data": 6
}
]```
Was looking for "Call"
thank you so much for your help bro
Neither is possible
Set the alpha to 1
Thanks it works
how can i make a weapon 2 handed?
Can items have enchants by default
no
Rip. It was going to be a workaround until the scripting thing I need comes to stable
Is it possible to change the texture of an item based on data?
i cant find anything about it
and if possible name or description, kinda like enchanted books
no
with lore, yes
which can be applied by using the lore function in loot tables, or you can set it with scripts.
custom items cant have default lore
Does anyone know how to make an item play a sound when you interact with it while holding it in your hand?
You can play a sound through the playsound command, the playSound method in scripting, or in an animation
using loot tables yes
e.g.
{
"type": "item",
"name": "minecraft:diamond_sword",
"weight": 3,
"functions": [
{
"function": "enchant_with_levels",
"treasure": true,
"levels": {
"min": 20,
"max": 39
}
}
]
},
Not what I meant but fair enough
u want to like have them have enchantments straight out the creative inventory or something?
also WHEN IS MINECRAFT GOING TO ADD ARMOR TOUGHNESS ON CUSTOM ARMOR
Pretty much, as a workaround until beforeEvents got entity hurt comes to stable
what are you trying to do if you dont mind me asking?
I have custom set of boots that increase jump height. But fall resistance doesn't change
i dont quite understand
what enchant are you trying to give it?
feather falling?
alternatively you can use damage sensors in the player JSON
but if you want to try avoid editing player json i understand
Yeah we have been strictly avoiding it
Isn't there a damage absorption item component?
I'm almost certain you can just make it disable fall damage
No that I know of
That's not the goal
reduced not disabled
I was looking at the item components earlier. Its there still
Well yeah not sure then
Waht does armor toughness do?
Is it possible to use the default item model in an attachable?
Ex: just rendering the item but allowing me to add animations to it
Also are custom spears possible? Looks like the vanilla spears are data driven but want to know if it's a dead end before pursuing
- No, you need your own model
- Yes
Can I remove armor equip sound?
Are you able to add vanilla items to custom item tags?
If theyre data driven yes.
probably last question for a bit, is there a way to use the dyeable item component so that I can color a texture, but prevent the player from actually dyeing the item themselves
Not that I know.
do you know if it's possible to use the same system that bedrock uses for coloring the firework charge texture? the bedrock samples has a white version but the behavior pack files are missing for firework charge so im not sure if that means its hardcoded or just not provided
tysm
But won't that cause problems with VV?
This is a armor I wanted to add for my addon where itโs a boot slot but goes onto your torso when equipped but I donโt know how to make it a armor does anyone know how I can achieve this
I've been told borion item hacks work...
How does one apply hides_player_location to armor directly? In their code
Add it in the component.
Yeah I tried it. Yet it doesn't seem to work.
Then I realizes I try to update the helmet to the newest format. And it just breaks the helmet
Works for me on latest format version.
What format do you use?
1.26.0
Mind if I send you a example of my helmet?
Open a post.
How to remove the 'No Effects' display from the Water Bottle?
Does anyone have a sample for a fishing rod?
how can i make an equip animation for an attachable
i can only ever get it to play once
{
"format_version": "1.17.41",
"minecraft:recipe_shaped": {
"description": {
"identifier": "skyblock:enchanted_wheat"
},
"tags": ["crafting_table"],
"pattern": [
"WWW",
"WWW",
"WWW"
],
"key": {
"W": {
"item": "minecraft:wheat",
"count": 16
}
},
"unlock": [
{
"item": "minecraft:wheat"
}
],
"result": {
"item": "skyblock:enchanted_wheat",
"count": 1
}
}
}
Why does my count for the recipe not work?
Because it doesn't exist, it's just for results.
Anyone knows how I can make a drink that can give you effects? Trying to make alchohol in minecraft
Either use food in format version 1.10 or use a custom component.
Thanks I used a custom component
Now I can finally get drunk with my friends in minecraft
lol
I wish I made a project this simple
All my ideas are long winded ๐ญ
Helloooo, is it possible to add a particle for attachment models and for the emitter to function under a certain animation?
Particles can be used in animation on attachables and work the same way, however they do not work on custom locators on the attachable geometry, so you will either need to do without use an alternative
dang huhu is it possible to do it another way tho?
any idea what does this mean
There is a way to do this but you would require using the player.entity.json file to add a locator in the player geometry, then you can add that locator to the attachable geometry, or just work in the player.entity.json file
But it's not possible to do with just the attachable
Its a bug, and not an intended feature, so I'm hoping they fix it soon
Though there's no clue as to when they fix it
Iโve been stuck on this for awhile I made all custom animations for the player but I donโt know how to make them work through a animation controller nothing plays does anyone know a template I can use for the queries or something
how do i make a item have a sword skill
Is there a way to decrement the durability of an item during recipes?
No
rip
What do you have in mind
As in something happens on right click/interaction
yes
You can use custom components or the itemUse event to make the item usable on right click
Anyone know how to play an animation of an item from a script?
You can use this tutorial to play them specifically through scripts
https://discord.com/channels/523663022053392405/1463304436330922014
or you can just use query.is_using_item if the situation calls for it, its much better when it works for your situation, but you might need the other one
its for pokedex
on pokemon addons
open and close animation
You'd definitely want to use the through scripts method then
I can't get it to work ๐ญ
Not sure if here or #1067869022273667152 is the best place, but is the drink animation hardcoded? I need it so I can modify it for an attachable.
Entities is the best place for animations, but don't worry, still relevant here too
It is hardcoded, but why not just make a custom animation to play instead
I was hoping to have the exact same animation, just adapted for the attachable. I can make it myself, but Iโm not great at recreating animations, so I wanted to double check. Thank you!
No problem, I hope it goes well!
hi would someone mind helping me: why is my custom component not working
import { world, system } from "@minecraft/server"
console.warn("Script loaded")
const onUseWand = {
onUse(event) {
console.warn("wand used")
event.source.runCommandAsync("setblock ~ ~ ~ stone")
},
}
system.beforeEvents.startup.subscribe(({ itemComponentRegistry }) => {
itemComponentRegistry.registerCustomComponent("raycast:useWand", onUseWand)
})
script is loading but command not running nor is 'wand used'
const onUseWand = {
onUse(event) {
console.warn("wand used")
event.source.runCommandAsync("setblock ~ ~ ~ stone")
},
}
Is not how you define the interface
Moreover, that is not how you define functions
Here is an example
So in your case, change it to this:
const onUseWand = {
onUse: (event) => {
console.warn("wand used")
event.source.runCommandAsync("setblock ~ ~ ~ stone")
},
}
both are correct.
Is it really? I guess I don't know JS ๐
yes, you can define a function like that too.
thanks anyway guys, got it working eventually. just rusty
does anyone know how to connect particles to a item or player, for example= i want to as if i where to use a particle and try and bind it to my hand it would move with the hand like if it was a item it self
like i were to play a animation it would move with the hand
is it possible to adapt trims to a custom armor model?
how i can fix this?
since i fixed mine the solution is adjusting the animation
so it wont cover your pov
i m using json and script api not addon maker app
instead of i using mt manager
okay
ok i figured out with help
am new to Modding and not rlly a good teacher maybe ask someone who is better
bruh i meant addons not modding
got too addicted on java
Thanks!
also how i can fix this attack anim?
-# without touching player animations of json
( Here's a complicated solution )
- Use Attachable
- Attachable's Model Binding to the head bone with molang condition
c.is_first_person ? 'head' : 'rightItem'so it doesn't swing with the hand - Make a custom swing animation and play it when
c.owning_entity -> v.attack_time > 0or smt.
and alternatively, you can edit animation.player.first_person.attack_rotation to disable the swing.
query.equipped_item_any_tag('slot.weapon.mainhand', 'tag') ? 0 : normal value
I think that count as "touching player animations of json"
glanced over the tiny text
lol
why dosent my recipe show up in the recipe book?
{
"format_version": "1.21.90",
"minecraft:recipe_shaped": {
"description": {
"identifier": "ma:common_tome"
},
"unlock": {
"context": "AlwaysUnlocked"
},
"tags": [
"crafting_table"
],
"pattern": [
" L ",
"PAP",
" P "
],
"key": {
"P": {
"item": "minecraft:paper"
},
"L": {
"item": "minecraft:leather"
},
"A": {
"item": "minecraft:amethyst_shard"
}
},
"result": {
"item": "ma:common_tome",
"count": 1
}
}
}
Is your item in your creative inventory?
I got it fixed it was a format version conflict across multiple items
How can I play the place item animation when I use my item?
You can't since there's no way to make the player swing using scripts
the first person item renderer is hardcoded so you can't apply animations to it without making an attachable which would create its own problems
well, then I will just do it without animation, thanks
How to restart a looping animation in an attachable?
I tried to create a pull animation using attachable, but I encountered a problem where it started in the middle.
there is a way to trigger the swing animation by using, you can just give it the throwable component with do_swing_animation true.
requires the projectile component aswell
to make it not throw the projectile, you'll need to cancel the item use with scripts.
it will play the shoot sound too
im pretty sure it didnt when I did this
hm
Use the "onUseon" custom component
no
its needs to be when you use it in general, not use it on a block
I solved it using a controller!
Is there a way to use costum elytras? I'm just confirming, since I understand that not
Personally, I think creating custom elytra is possible. But for casual dev, it would be a nightmare because you need to manually calculate all the angular momentum (Mostly via ScriptAPI).
Most Custom Elytra you see are just reskinned Elytra with different textures.
hey folks, is there a way to cancel the book UI from opening and instead open my own UI??
do you mean like a server form in scripts?
If it's just for the server UI, wouldn't you just create a custom item?
maybe they want like a sneak interaction thing for the vanilla book for some reason
I'm desperatly trying to create a "fake" book, that looks like a vanilla book but loads a custom UI, i have the custom item, but its 3 times the size of a vanilla book even though i used the vanilla texture 16x16 and i just cant get the attachable i have to add to scale it to sit right in the players hand, so....... plan B was to give the player a standard book, git it some lore and detect on itemUse and getLore to load the custom UI, but it just loads the vanilla book UI
Are you making an attachable that's causing it to be bigger?
Regardless, https://stirante.com/script/server/2.6.0/classes/WorldBeforeEvents.html#itemuse Use beforeEvents.itemUse->cancel the interaction then show Form.
Documentation for @minecraft/server
i'm making an attachable because i need to scale it down. It need to look identicle to a normal book as certain players have a book the opens a special menu and other players have just a book..... i totaly forgot to look at the beforeEvents
Why do you need to scale it down if it's already 16x16?
In 1st person, it looks the right size, in 3rd Person its about 3 times a big and the wrong angle in the players hand
I have 0 clue how that could possibly happen.
Can you show me your code?
i know right!! and the only way i know to solve it is to create an attachable and animation and correct the scale/rotation using that OR intecept the itemUse with a normal book and direct it to a custom UI
which bit?? the item??
Yea
"format_version": "1.21.0",
"minecraft:item": {
"description": {
"identifier": "mbb:sabotage_book",
"menu_category": {
"category": "equipment"
}
},
"components": {
"minecraft:display_name": {
"value": "ยง6ยงlSabotage Book"
},
"minecraft:icon": "sabotage_book",
"minecraft:max_stack_size": 1,
"minecraft:glint": true,
"minecraft:hand_equipped": true,
"minecraft:allow_off_hand": false
}
}
}```
That's the problem.
You are using the "minecraft:hand_equipped" component.
Gad Dang it!! i didn't even think to look at the item components!! it does pay to read the documentation. many thanks
Ugh, the mc wiki.
Yea 
i should update the wiki with example images!! That was a waste of several hours trying to fix a problem i didnt know i caused!! ah Bedrock Development, what a heartless bitch you are!!
Both wikis are good, but the Bedrock Wiki is more focused on creators, while the Minecraft Wiki is more for documentation.
Well, if you read this, it already explains it.
Nah.
very true, but not knowing that "rendering like a tool" is different to rendering like everything else in the game, does make both wiki's moot
Well, I think everyone knows that the tool is rendered differently to appear larger and better in hand.
well i certainly do now 
Anyone know how I can sort spawn eggs in the inventory?
Trying to use crafting item catalog, but I am getting the content log about category originally being set to items now being changed to nature... Just trying to order the default spawn eggs for my custom entities but I guess I can make a custom item to spawn them
does anybody know how to lengthen a sword's texture?
like how to make it very long
cant use locators in attachable models. Hence cant effectively use particle animations as well.
I've heard that apparently if you reference a locator present on the player geometry, you can make an attachable create useful particles in animations
I haven't tried it, however
The problem still remains though. I want a locator that is attached to attachable model and not player model. Especially because editing player.json or player model is not good according to addon guidelines
guys what are dynamic properties and what does it do ๐ญ
@ me if anyone does have info
pls
I meant there is the lead_hold locator for people who want to affect the hand only
Dynamic properties are a form of saving data in scripting, where you can save data as a:
- string,
- Vector3,
- integer,
- float
- and boolean,
under a string identifier to a: - World
- Entity
- ItemStack
Yes and that is inconvenient. Image you want to spawn particles at left hand side or head or whatever position attachable is attached to. So locations and particle animations should be properly supported in attachable animations and models.
Can i use it for eg in a katana that allows the user to use 2 abilities and shift between each one?
As in like when a dynamic property is this, the ability is lets say ab1 and when we change dynamjc property the ability is ab2
Yes, you can
When you right click, you can set the dynamic property to a value, and every right click you can check the value of the dynamic property, to change the property perform the other ability
Where is this part located in the Bedrock sample UI file? I've tried searching through the HUD screen and found nothing related. I currently want to customize the tooltips of the items a bit, so I really need this information. Does anyone know?
probably lore with custom emotes
It's Item Lore and Glyph. Not JsonUI
"minecraft:display_name": {
"value": "item.bucketCustomFish.name entity.blaze.name"
}
Why does this not work?
It should show Bucket of Blaze forexample
What does it say?
You need % in front of the keys.
Ohh
%blah1 %blah2
is this wrong then?
https://wiki.bedrock.dev/items/item-components#display-name-object
No. Because that is only 1 lang key.
Okay thanks
works thanks
wait do I need to put a space between the keys?
so like
%... %...
or can I do
%...%...
bc the one without space doesnt work
and the key item.bucketCustomFish.name does have a space in it
so its like double space
in the name
Remove the space then?
I did but now its works
"%item.bucketCustomFish.name%entity.blaze.name"
I meant in your lang key.
its the default minecraft one
here its in the lang files
item.bucketCustomFish.name=Bucket of
it has a space in it
Use a custom one.
If I do that I have to do it for every language thats why I used the mc one
Oh I found a bug
in the hotbar its fine but in the inv its buged
and I found a solution by adding ยงr
Is it possible to make when only certain experimental is on it register the item?
like Education Edition items
This is a Minecraft bug when setting the name via script.
I dont set it via script
No? Well, it should be a similar problem.
I also found another renamed item bug
zombie pigman called zombified piglin
but when you want to spawn one it called zombie_pigman
Thats not a bug. Thats just them not updating the id bc it would break things.
oh ok
It would be nice to have a system for them to convert the ID; in fact, this was already done once with the villager.
is there a work around?
Hey Iโm looking for someone to make me a custom weapons mod
You found this place to make add-ons and resource packs or ask for them? Consider making simple packs yourself!
yall what are some good ideas for a trident recipe, i am adding custom items and recipes so anything goes,
wondering cuz im a mod for superflat and i dont want to just change the loot table for drowned cuz I'm lazy that way and think crafting is cool
8 nether star with 1 deepslate diamond ๐
Can I replace properties of vanilla items such as a dragon egg?
Nope.
Are there any workarounds I can do? Like, remaking a dragon egg item?
๐ญ
Yo! Is there a vscode extension that have auto completions for any json files like items, blocks, ect.
any good videos or guides on how to animate attachables with hands in blockbench?
A question: would it be possible to create an item or script that makes a crafted item already come with enchantments? Without needing the player to hold the item and use /enchant on it?
Smash bros in literal
I tried to make a throwable fireball item and it just shows the item with 64 stack without icon
{
"format_version": "1.21.120",
"minecraft:item": {
"description": {
"identifier": "tomoko_cult:throwable_fireball",
"menu_category": {
"category": "equipments"
}
},
"components": {
"minecraft:projectile": {
"projectile_entity": "minecraft:fireball"
},
"minecraft:throwable": {
"do_swing_animation": true,
"launch_power_scale": 1.0,
"max_draw_duration": 0.0,
"max_launch_power": 1.0,
"min_draw_duration": 0.0,
"scale_power_by_draw_duration": false
},
"minecraft:glint": true,
"minecraft:max_stack_size": 16,
"minecraft:icon": "minecraft:fireball"
}
}
}
Does anyone know what did i do wrong and how to fix it?
Are there any log errors occurring?
Yup just figured it out, i used the wrong format version
And this one it' cuz i put invalid menu category
What does LevelSoundEvent mean?
The hardcoded sound stuff.
๐ In 26.30 however, we can use custom sounds.
How do u do that?
Just define it in sound definitions and then use it. ๐
So the record component is usable now?
In 26.30 yeah
But remember, this is experimental and requires the beta APIs option.
Ok ๐
Is there a way to enable experiment with achievement on?
I would wait for it to stabilise ๐
No, as Smokey said, in this case it's better to wait for it to stabilize. I SUPPOSE it might stabilize at 26.40.
Can someone show me how to make item component that triggers when hitting entity
I tried using the wiki item event tutorial, and it didn't work
So i messed around and got here:
import { system, world } from "@minecraft/server";
/** @type {import("@minecraft/server").ItemCustomComponent} */
const effectHitComponent = {
world.afterEvents.entityHitEntity.subscribe((event) {
event.hitEntity.runcommand("function tomko/weapon_hitted_punish")
event.damagingEntity.runcommand("function tomko/weapon_hit_buff")
}
};
system.beforeEvents.startup.subscribe(({ itemComponentRegistry }) => {
itemComponentRegistry.registerCustomComponent("tomoko_cult:reward_punish", effectHitComponent);
});
Content log said it was missing a }
dang i wish shapeless recipes can give multiple results
is there a bug report for this?? items colored with dyeable not having color in offhand
Send in #1469393984161054833
Can using scripts like addTag make custom item tags or no?
No, you cannot dynamically add tags to items.
Is there something close to this not like this exact idea but like adding something like tag-esc to an item or no
If not that's fine
Unstackable items with dynamic properties.