I was wrong. Right Click Detection is here. For real.

  Рет қаралды 46,123

Conure

Conure

Күн бұрын

Ironic that food is used in the "non-consumable" method...
Tutorial Datapack - drive.google.c...
Consumable Right-Clicks - Knowledge Book Method • Knowledge Books are st...
come hang out on Discord, if you feel brave enough / discord

Пікірлер: 390
@conure512
@conure512 8 ай бұрын
Some answers for questions I've been getting a LOT of: *"Why can't you just set the speed to a higher value when right-clicking?"* Short answer: FOV effects. Eating doesn't change your FOV, but attributes and effects do. If you mess with the player's speed while they're eating, their FOV will be increased for the duration, which will look weird. Feel free to do it if you're okay with that - but I personally don't like it. Yes, you can disable this by turning off FOV effects for only yourself, but if you're making a datapack, that would require ALL USERS to do this, which isn't exactly practical. *"Can't you just use /schedule instead of those ticking advancements?"* No, and there are two main reasons why. 1. Scheduling causes conflicts in multiplayer. A scheduled function cannot be assigned an executor (it defaults to just being run by the server console), so you'll lose any information about who the cooldown is for. There ARE workarounds for this, but none of them are as clean as the ticking advancements, which act like a personal timer of sorts. 2. Even if you were able to get around the multiplayer issue, there are issues involved with players disconnecting from the server during their cooldown. A scheduled function would revoke the player's using_item advancement once time is up. The problem is that if the player disconnects from the server before that happens, the function won't have anyone to revoke the advancement from - and when that player reconnects, the schedule will already be over, they'll still have the advancement granted, and they'll effectively be softlocked and unable to use the item again. With the ticking advancements, the player's personal timer also stops when the player leaves, and will resume as normal when the player comes back.
@MysticMicrowave
@MysticMicrowave 8 ай бұрын
Is there any ways to change fov as well? Like with the spyglass?
@CallMeCarlos1
@CallMeCarlos1 8 ай бұрын
Do you really think 1 million seconds is gonna stop me from eating my magic wand?
@Luna5829
@Luna5829 8 ай бұрын
68 years will though (java integer limit)
@TheMiningCrafter
@TheMiningCrafter 8 ай бұрын
@@Luna5829 yes but 1 million seconds is only 11 days
@Luna5829
@Luna5829 8 ай бұрын
@@TheMiningCrafter the datapack uses integer limit tho
@TheMiningCrafter
@TheMiningCrafter 8 ай бұрын
@@Luna5829 yes but if it doesn’t reach said integer limit nothing will happen
@jsabasakapa
@jsabasakapa 7 ай бұрын
Im wondering what -1 do
@Larkky
@Larkky 8 ай бұрын
Minecraft needs a "dummy item" that is not used in any crafting recipe, cannot be crafted, smelted, grinded, etc. and has no use at all. itd be useful for map makers and command blockers
@optiant
@optiant 8 ай бұрын
petrified oak slab prolly or spawn eggs with nbt data to not do anything
@egekahraman8985
@egekahraman8985 8 ай бұрын
I think poisonous patatoes may qualify depending on if being eatable messes things up
@404maxnotfound
@404maxnotfound 8 ай бұрын
There are a couple just don't remember them off the top of my head but poisonous potato+this method for rightclick detection could work since there is can't be used in any crafting recipe, etc and it disables the editable function of the normal potato.
@eddie1538
@eddie1538 8 ай бұрын
As far as I'm aware the only item like that is the clock.
@Capiosus
@Capiosus 8 ай бұрын
knowledge book?
@Sabagegah
@Sabagegah 8 ай бұрын
For extra Silly, use the Continuous Flame Wand for 1000000 seconds anyway. Be the worst wizard in history. “Hey, where’s my wand?” “Sorry, I got hungry.”
@ezren_7140
@ezren_7140 8 ай бұрын
FYI this is 11 and a half days lol
@conure512
@conure512 8 ай бұрын
@@ezren_7140 In the actual datapack I have the time set to the java integer limit, which is over 2 billion lol. That works out to 68 years.
@Sabagegah
@Sabagegah 8 ай бұрын
@@conure512 Advancement Made: Seriouser Dedication
@alexdanovyt9032
@alexdanovyt9032 8 ай бұрын
@@conure512 nah bro just leave it at like 10k seconds (3 hours) and make it if you actually eat the item you get an easter egg item 💀
@Syonico
@Syonico 8 ай бұрын
@@conure512 give a man a wand, he'll eat for 68 years teach a man to make a wand and he'll eat for a lifetime
@uraid
@uraid 8 ай бұрын
it’s still kinda funny that if you hold cast for long enough eventually you’ll start eating your wand
@justvladcreate
@justvladcreate 8 ай бұрын
So basically here you explained, how you made a looped advancement cycles to improve optimization by getting rid out of constant tick and making it once upon use tick. Smart
@DqwertyC
@DqwertyC 8 ай бұрын
Aw man! I was trying to solve the delay issue by scheduling and unscheduling functions, but this seems much more robust. FWIW, if you still want consumable right click detection, set the time to eat to .05 seconds. Eating is instantaneous (a single tick) and only shows a spray of particles without the eating animation.
@conure512
@conure512 8 ай бұрын
Very good to know! I tried that eating trick a while back but I guess I didn't set the time short enough, because the animation was still there. And with that, we'd be able to use consume_item instead of using_item!
@mini-prince.1233
@mini-prince.1233 8 ай бұрын
would be rly cool if you did a comparison video showing the pros and cons of each method (carrot/fungus on a stick, eye of ender, food, knowledge book,...)
@nuklearboysymbiote
@nuklearboysymbiote 8 ай бұрын
yo that's mad! back in 1.19 i figured out how to use a trident to create an item that triggers one effect while you're drawing it back, and another effect when you release. i also made it cancellable by switching offhands :D Oh also i resolved the walking speed issue by setting movement speed attribute to 5 times the normal while drawing back the trident, and setting it back to normal on release or cancel. Works every time 90% of the time…🤣
@Game_Blox9999
@Game_Blox9999 8 ай бұрын
NnNnNeEeEeOoOoOwWwWw!
@Sollace
@Sollace 8 ай бұрын
Conure: "So, if you need an item that you can use which doesn't slow you down..." Swift Sneak Enchantment: "Hold my enchanting table"
@conure512
@conure512 8 ай бұрын
Does Swift Sneak affect your speed while eating? If so I did not know that lol
@CaliSPICY
@CaliSPICY 8 ай бұрын
@@conure512 no it doesn't
@shureee1
@shureee1 8 ай бұрын
how about changing generic movement speed while consuming the item?
@Sollace
@Sollace 8 ай бұрын
@@conure512 I'm not sure, lol, but there's also the speed boost potion effect.
@As1anCr4ck3r
@As1anCr4ck3r 8 ай бұрын
@@shureee1 you can change the generic movement speed for the player to combat the slowness but it makes that weird zoom thing on the screen
@anidiot5153
@anidiot5153 6 ай бұрын
can we just appreciate that we can now eat our diamond sword if we wanted to because "sorry i was hungry"
@Peastable
@Peastable 8 ай бұрын
I’m always glad to find another high-quality datapack channel. This is super cool!
@towers4506
@towers4506 8 ай бұрын
This is really cool! You could try giving the player speed when eating, or removing and giving back the item to cancel the eating animation. It could also be cool to have a falling edge wand, that only functions when click is released (like the bow)
@xelus_gg
@xelus_gg 7 ай бұрын
Glad I found your channel! I love this stuff and learning what we can do with just the vanilla game! @3:20 - slowing the triggering * hertz can be done through the advancement conditions using: entity_properties -> "periodic_tick" :D
@conure512
@conure512 7 ай бұрын
Yes, periodic tick works too! (This video is slightly outdated now, I made it for 1.20.6 and that hadn't been added yet lol) I will say though, if the period is long enough, using periodic_tick can make it feel less responsive because there might be a delay between your first click and when you're actually able to use the item. With this method, you're always guaranteed to have it activate as soon as you click.
@xelus_gg
@xelus_gg 7 ай бұрын
A lot has changed in a month hey! @@conure512 I learnt about the resposiveness recently too. I just put together a right-click auto-harvest feature for a hoe! :D I used ^ and '..aligned eyes' from this video to do a crude raytrace
@turmspitzewerk
@turmspitzewerk 8 ай бұрын
i'm glad you popped up in my reccomended two days in a row, seeing another one of your vids made me realize that you're really good at making cleanly edited, entertaining videos. keep it up 👍
@kuronya3582
@kuronya3582 8 ай бұрын
using advancement as tickless trigger is something fascinating for me
@jq1245
@jq1245 8 ай бұрын
Im currently working on a spellcasting datapack using your knowledge book method! I think I'm going to incorporate these methods too, as wands or staffs. Love your work!
@As1anCr4ck3r
@As1anCr4ck3r 8 ай бұрын
You have no idea how amazing this is for me. I have been waiting for right click detection that doesn't involve a carrot on a stick in the offhand or even an eye of ender. All I need now is a way to make the Icon of an item in the hotbar different from how it looks in hand and I can die happy
@nonexistentsquare2092
@nonexistentsquare2092 8 ай бұрын
This is possible using custom model data
@As1anCr4ck3r
@As1anCr4ck3r 8 ай бұрын
@@nonexistentsquare2092 I know how to make custom models already, but you know how the trident or the spyglass has a pixel art icon in the hotbar but shows a 3D model in hand and in POV, I dont know how to do that
@j.a.v.mersbergen5443
@j.a.v.mersbergen5443 8 ай бұрын
This channel is sooooo underrated!
@SuperBro112Lol
@SuperBro112Lol 8 ай бұрын
im surprised his videos even appear on my home page
@matiera_scape
@matiera_scape 8 ай бұрын
While I don't know all of these magic words, I did enjoy the video lol Congrats on 1k subs Conure!
@fgdx
@fgdx 8 ай бұрын
This is such an incredible way to do the cooldowns, kudos to you.
@vindi167
@vindi167 5 ай бұрын
for those who think they can just hold right click for a crazy long time and eat the item, no you can't. at some binary integer limit (probably like 65535 or something) the game just calls it "infinity" and treats it just like infinity.
@thenextdoor696
@thenextdoor696 8 ай бұрын
These last few videos convinced me to sub to this channel, great job dude!
@PenelopeNaomi
@PenelopeNaomi 8 ай бұрын
I like the slowdown when using it because if it's specifically magic usage it makes it seem like you're focusing when using it.
@virtu6607
@virtu6607 8 ай бұрын
Now I just need fully implemented component crafting and I will be happy
@dyrania
@dyrania 4 ай бұрын
Your innovative advancement method can be described as such. The addition of tick functions inside advancements only when specific conditions are met. If I'm incorrect about my interpretation of this please let me know. But otherwise, it seems to be a revolutionary form of datapack efficiency. This is honestly game changing information, thank you so much.
@_rubl
@_rubl 8 ай бұрын
the only advantage coas still have is that you don't slow down while using it
@Teacup44
@Teacup44 3 ай бұрын
@KZbinFie fov effects
@observerdot2107
@observerdot2107 8 ай бұрын
This explains why when some mods break, if you right click them it starts the eating animation
@TheiBunny
@TheiBunny 8 ай бұрын
To expand on the point you kinda make at the end; I dont think this makes other methods obsolete. Moreso just broadens our options for how exactly we want right-clicking with a given item to work. Two big drawbacks of this method are: - slows player movement while using. - item in hand bobs when initially used. I can definitely think of some applications where those aspects would be desireable, but I think its fair to raise them as limitations, because depending on what you want to do, they can be. The carrot on a stick doesn't bob or slow the player down to use, and can now be given whatever other item components you want it to have to mimic the behaviour of another item(s). But because it isn't *actually* that item, it won't natively have the special mechanics/properties some items have, such as; being throwable, used to lure animals with, used on a certain blocks/entities, as fuel or ingredients in recipes, etc... (this is an advantage of using the desired item with a high eating time - however there are workarounds for most situations. It optionally having durability used to be a plus, but thats a non-factor now.) Goat horns with a specified custom, blank sound file are another option if you want an item with a built-in cooldown timer before it can be used again, but it has the downside of the subtitle still showing up when enabled (which could cause confusion/"break the magic") + the animation, and it still has the same limitations of the carrot on a stick. (of course there are other ways to do cooldowns, and with some custom model data trickery you can have custom cooldowns that look the same as the existing vanilla item cooldowns too - but the benefit here is that its built-in to the item.) Teleporting an interaction entity in the player's face constantly is an option if you want to prevent the player from interacting with the environment altogether, and for both right and left click actions to *only* go through whatever systems you've set up instead... (only really good for specific custom maps that need it, probably not suitable for add-on style data pack content for any old world) Knowledge books are by far the least useful now, but still have a niche... They behave similarly to carrots on sticks, but are consumed when used. (prior to 1.20.5 - before the stack size component was added - this was a perk, but its pretty trivial to delete 1 item now that any of the other methods can be stackable items if you want them to be... Tho I guess if it meets your exact needs in the fewest no. of commands being run then its good for optimization? lol)
@conure512
@conure512 8 ай бұрын
Some very good points. Carrot on a stick definitely has some capabilities that other options don't, but to me it will ALWAYS be a last resort because it requires ticking commands. I'm probably going to use the knowledge book method quite a bit from here on out, for stuff that's meant to be consumable.
@TheiBunny
@TheiBunny 8 ай бұрын
@@conure512 fair enough! I tend to prioritize the look and feel of a mechanic to the player in my packs over exactly how I get there behind the scenes, but the speed and efficiency of knowledge books/"edible" items is a *very* good reason to go with them over the carrot on a stick for projects if you don't mind the few "drawbacks".
@IwrsTheKing007
@IwrsTheKing007 8 ай бұрын
you can also just check for the data food={nutrition:0,saturation:0,can_always_eat:true,eat_seconds:1000000} then you don't need the custom data, unless you need it for something else
@conure512
@conure512 8 ай бұрын
Right, but if you have multiple of them that use the same food mechanism and are the same underlying item, custom data is nice to differentiate! I typically get in the habit of assigning custom data to my items anyway when I'm making a large item datapack, it just helps to keep everything organized.
@IwrsTheKing007
@IwrsTheKing007 8 ай бұрын
@@conure512 right, didn't think of that, makes sense
@abraxas2658
@abraxas2658 8 ай бұрын
The impulse gem is 90% of the way to charging an effect that occurs on release
@FACS01
@FACS01 8 ай бұрын
@minecraft please add an food component tag to set a custom walking speed while eating
@jakeklic
@jakeklic 8 ай бұрын
this is everything i’ve ever wanted, thank you
@Gameatronic9000
@Gameatronic9000 8 ай бұрын
gonna be honnest. i love this. about 2 years back i was on a vanila server with some friends and wanted to makea fatapack for simple seats. fpr right clicking i needed to make a command to place a display entity on a block, and a rogjt click on that for riding it, and a helper function to easily delete the nearest seat. but i was never fully happy woth it being display entites cause it would block you from building in that spot unless you has an admin run that deletion command. and the only other option i could ever find was carrot on a stick. NOW, i could mKe a custon recipie for 2 tools, create seat, and break seat. simple tools than when clicking a block make or break a seat display entity like the impulse gem. alternativly, i could have it be that if click and facing stair block, sit player at stair possition. past my own junk, this is revolutionary for a myriad of reasons. caus ethe speed problem is just gove the player a boost by modifying attributes for their speed while clicking and we never have to use carrot on a stick again. blessed be this day, we're no longer a bunch a piggies
@Kirisame_Soup
@Kirisame_Soup 8 ай бұрын
For the delayed wand you can also do a scheduled command loop on the load function and check for advancement to trigger particle (if that's simpler)
@dojelnotmyrealname4018
@dojelnotmyrealname4018 8 ай бұрын
Hey, since bowl items return their bowl when you eat them, could you A: set the return item to something useful and B: Use an instant eat time, to detect right clicks that way?
@conure512
@conure512 8 ай бұрын
You can indeed set instant eat time, but you can't inherently change the returned item. You'd need to set up an advancement or something that detects when you eat that item, then clears 1 bowl from your inventory and gives you the item you want instead.
@sobanoodles4286
@sobanoodles4286 8 ай бұрын
Take a drink every time he says Tick
@FriedMonkey362
@FriedMonkey362 8 ай бұрын
Wow using that last bit you can essentially detect button down and button up, which is even hard to do in some programming languages, also you can get the state if your holding it down at any time by checking of the score is 2
@austinlinco
@austinlinco 8 ай бұрын
How has no one thought of this… oml
@Cat-pv6yx
@Cat-pv6yx 8 ай бұрын
There was a post on this being the ultimate click detection method on Reddit
@henrycgs
@henrycgs 8 ай бұрын
I remember when mojang first added advancements. one thing you could do was running commands upon getting an advancement, so obviously people abused it to run commands every tick and get rid of command blocks by moving everything to the advancements. mojang hated that, so they replaced the whole system with functions. it's like i'm seeing history repeat itself... hopefully mojang notices this and adds proper right click detection :)
@conure512
@conure512 8 ай бұрын
hey man if they just straight-up add right click detection, I would not complain for a second hahaha
@henrycgs
@henrycgs 8 ай бұрын
@@conure512 I know right!! and with the new components system I think we might be heading in that direction
@ImRei44
@ImRei44 4 ай бұрын
for the last item, you can also use goat horns and change their model with a resource pack. you need a ticking command (sorry) but it has a 10 seconds cooldown which might be useful for items like wands
@Ruffilicious
@Ruffilicious 8 ай бұрын
thank you. I hope we see more of the good stuff
@Kirisame_Soup
@Kirisame_Soup 8 ай бұрын
For the third wand, you might be able to use the wand's advancement tick to grant another advancement where particles spawn, and on the wand's advancement tick schedule a function that has a 2 ticks delay with the replace type, which revokes the second advancement, so that after a tick when the wand is released the second advancement is revoked and ready to be granted again
@conure512
@conure512 8 ай бұрын
Nice idea! I personally try to avoid scheduling wherever possible because scheduled functions tend to cause issues in multiplayer, but im sure theres SOME way around it lol
@Kirisame_Soup
@Kirisame_Soup 8 ай бұрын
@@conure512 Oh yeah, that's indeed, hmm
@Izzythemaker127
@Izzythemaker127 8 ай бұрын
If it slows you down and is held that means it would be possible to create a custom bow by using the impulse gem except on hold it does nothing except increase a counter if it isn't maxed out, and then when cooldown ticks down from 2 it would create an arrow projectile.
@justanicemelon9963
@justanicemelon9963 8 ай бұрын
Never knew minecraft eating would be this game changing
@chimpedout
@chimpedout 8 ай бұрын
They added a new attribute that changes movement speed that I’m pretty sure doesn’t alter your fov edit: nvm I think I’m tweaking
@NathanHaaren
@NathanHaaren 8 ай бұрын
You could make a spell book with this, read the book to cast a spell, like a hailstorm or a firewall, have some rare spell books that you actually completely "eat" to cast
@Teacup44
@Teacup44 3 ай бұрын
for said rare spellbooks, eating_time should be 0.05 (single tick)
@lysibee
@lysibee 8 ай бұрын
Fun fact, but resetting a scoreboard is actually more laggy, than /set 0
@heckerhecker8246
@heckerhecker8246 8 ай бұрын
this is cursed
@KarachoBolzen
@KarachoBolzen 8 ай бұрын
The knowledge book method could actually be cool though, imagine it spawned your spellbook in front of you to shoot the spells out of, before returning to your hand. Also a very natural cooldown mechanic. I was imagining something like the floating book of an enchanting table, but apparently it doesn't come separate from the table which is pain.
@zwatotem
@zwatotem 8 ай бұрын
I was never into datapack programming. I just clicked the video. But man... This is worse than JavaScript. This may even potentially be worse than C++ template meta-programming. Mojang should really tighten their butts and give you a serious tool (full fledged scripting language) for the job instead of a mix of commands, scoreboard operations, NBT tags (or whatever the new thing is called), advancements, etc. Like for real. I feel like every tool they give is not sufficient for it's intended use. They introduced scoreboards, and teams and I don't see them ever used as intended. Small private servers don't use them at all for displaying statistics and setting up teams because they have no GUI and nobody knows, how to set them up. Big servers don't display statistics directly, but use them as display banner for their custom info with the 15 14 13 12 .. 3 2 1 trick. They added customizable border back then, but I really seldomly see that used either. It only works horizontally and can only have rectangular shape, and of course you can configure the effects of being outside it, so all the servers use custom borders. I wish Mojang either gave easier to use tools (with GUI for example) so that they can be used by small communities with ease, or give more powerful and configurable ones, so that they are actually useful in Player Experience creation. (Although they are progressing with display entities and I suppose NBT rework is an enabling change, so maybe we'll slowly get somewhere)
@staxpy5729
@staxpy5729 8 ай бұрын
Amazing ! Clear and straight to the point. Great explanations ty, that's super useful !
@mittens567
@mittens567 8 ай бұрын
Congratulations on 1k!
@NeunEinser
@NeunEinser 8 ай бұрын
04:00 you could also simply schedule a function that has the /advancement revoke for the original advancement. I am pretty sure the tick advancement is not free, the game internally most likely checks every tick if the advancement is granted, and might have additional overhead from checking if the advancement has conditions, etc. I am not sure if this is better than an execute if in a ticking function, needs benchmarking, and/or code analysis.
@Samstercraft77
@Samstercraft77 8 ай бұрын
thats game-changing btw vscode has extensions for syntax highlighting for mcfunction format if you're interested in that, might be easier than notepad
@CrazyMusicBoy44
@CrazyMusicBoy44 8 ай бұрын
for single use right clicking, what happens if you set the eating time to 0?
@conure512
@conure512 8 ай бұрын
I'm pretty sure it has to be a positive value, but you can make it really tiny, and then you could feasibly detect it with the consume_item trigger. Only problem is it always displays the eating particles and plays the sound.
@the_rahn
@the_rahn 8 ай бұрын
A solution to the slowdown might be to give the item a speed atribute increase while active, but that might mess with the fov... Otherwise, this is a big breakthrough!
@arendvandermerwe3309
@arendvandermerwe3309 5 ай бұрын
So your telling me... that if i dont let go of my guns trigger for 10 years... i will start eating it...
@KwikBR
@KwikBR 8 ай бұрын
isn't there a way to change player speed without changing the FOV? on lots of non-modded servers i've been in there's a walkspeed command, which changes playerspeed without changing the fov, isn't that a datapack?
@conure512
@conure512 8 ай бұрын
That's probably done through plugins, not datapacks. Especially if this server had custom commands - those can't be added with datapacks, so the server definitely has plugins on it lol
@KwikBR
@KwikBR 8 ай бұрын
@@conure512 I had no idea that there was a difference, sorry
@Pikatscha
@Pikatscha 8 ай бұрын
I'm feeling now very stupid for not knowing, that you can put a return in a function. I never know and used function now for quite a while
@dragon3025_
@dragon3025_ 6 ай бұрын
Thank you. Wow, this is a much better way of handling right click detection. 😁
@MadelynofHell
@MadelynofHell 8 ай бұрын
Can you not just give the player speed while they're using the wand ro avoid the issue wutg eating slowing you down?
@rx97_mc
@rx97_mc 8 ай бұрын
The tick trick is neat. I haven't seen it used in this way, but I generally have done something similar with `schedule` loops. This is nice bc it's per player. I will note, advancements *can* be slower if they are granting every tick so I would make sure that's thought about (a persistent ticking advancement is likely worse than `#minecraft:tick`)
@myboyaks8065
@myboyaks8065 8 ай бұрын
I think this is better than carrot on a stick because more items that can be used and just combine them with resourcepack(custommodeldata for custom item). Also because if someone using someone’s datapack but they dont want to use the rsp, they wont see carrot on a stick instead they will see an item that can be similar to the resourcepack(sword remodel than carrot on a stick remodel as a sword)
@funnydotyes
@funnydotyes 8 ай бұрын
you could create a flamethrower with actual ammo with this due to it being consumed
@arcanine_enjoyer
@arcanine_enjoyer 8 ай бұрын
Mojang not adding the ability to create custom items, mobs, etc. easily with datapacks is the reason why modded will always be preferred over datapacks
@Doodle128
@Doodle128 8 ай бұрын
Make it apply a speed effect when eating
@krispyking2450
@krispyking2450 8 ай бұрын
they should add a component saying how slow the player should move when active
@helohel5915
@helohel5915 8 ай бұрын
1.20.5 is already out ;) cant wait to see what you can do with the new stuff
@conure512
@conure512 8 ай бұрын
I have a suspicion that they accidentally released it early. (as in like several hours early.) the launcher has 1.20.5 but no announcement for it, SlicedLime has his announcement scheduled to drop in 1 hour... it's like they had the whole thing planned out but accidentally pressed the big red button without realizing it lmaooo
@helohel5915
@helohel5915 8 ай бұрын
@@conure512 yeah I've been playing the prereleases on my server and got confused why I couldn't connect and checked the updates and boom, 1.20.5 was right there.
@live_destin-3408
@live_destin-3408 8 ай бұрын
*Just change the speed multiplyer on the held item as long as the player is holding down right click. If you set it to just the right speed, it will negate the slowness*
@tom.h2060
@tom.h2060 7 ай бұрын
Hey, this is quite impressive. However as a map maker, I pay a lot of attention to the number of lines of code I use to realize a specific ingame function. In terms of the number of code lines, the solution with a carrot on a stick and scoreboard wins. In terms of flexibility, this is definitely the best solution, as you don’t need to make a ressource pack to change the carrot on a stick texture. I'll keep your solution in mind as it is very interesting ;)
@conure512
@conure512 7 ай бұрын
Number of lines is a great place to start, but you've also gotta consider how often that code is being run by the server. With carrot on a stick, you need to have 1 line running every tick (20 times per second), whereas with this method, no code is running at all most of the time. So overall, this method actually runs far fewer commands than the carrot on a stick, even though the number of written lines in the datapack is higher.
@LeshaTheBeginner
@LeshaTheBeginner 8 ай бұрын
9:49 or while you're using the item set your base attribute speed to the normal speed to cancel out the slowdown
@TrxtaTutto
@TrxtaTutto 6 ай бұрын
I'm not smart enough for this, I'll keep using the carrot on a stick
@Zanophane_Gaming
@Zanophane_Gaming 8 ай бұрын
Chat, resource packs are going to go absolutely insane in 1.21
@conure512
@conure512 8 ай бұрын
What do you mean by "chat resource packs"? Did they add something to respacks that can affect the way chat looks, and I just completely glossed over it?
@Zanophane_Gaming
@Zanophane_Gaming 8 ай бұрын
@@conure512 Slight punctuation error, sorry about that. This is also a joke where people go "hey chat is this real" so I'm more so parodying off of that.
@conure512
@conure512 8 ай бұрын
Ohh haha gotcha. Yeah I'm hoping we get some cool stuff for resource packs as well, we havent gotten any major upgrades for those in a while (the focus has been so much on datapacks)
@Blazecaster
@Blazecaster 8 ай бұрын
In theory could you create an overheating system utilizing the eating function returning a temporary item upon completing the eating animation?
@FakeFurball
@FakeFurball 8 ай бұрын
Could you add a speed boost effect to the function to negate the "eating" debuff?
@jamesharding7536
@jamesharding7536 8 ай бұрын
Use the movement speed attribute to offset the eating slow
@404maxnotfound
@404maxnotfound 8 ай бұрын
Nice no more eye of ender trick.
@shureee1
@shureee1 8 ай бұрын
what about changing player's attribute and make their generic movement speed higher during the time when consuming the item? wouldn't that just make it flawless?
@conure512
@conure512 8 ай бұрын
Changing speed would also mess with the player's FOV, because eating slows you down WITHOUT changing your FOV. So, still not a perfect solution lol
@shureee1
@shureee1 8 ай бұрын
@@conure512 one thing or the other, quid pro quo :/ I imagine using these custom items as custom weapons for example, so it would be useful if one was able to run and attack simultaneously without any unconveniences
@shureee1
@shureee1 8 ай бұрын
in the end, it's very cool that we can have something working just as the ender eyes, but unlike them, they can be used on survival worlds flawlessly, very cool video and I have so many new ideas! thank you
@Systolic_Gaming
@Systolic_Gaming 8 ай бұрын
7:02 This looks alot like the inverse of a bow, where it fires then needs to charge back up. Im a novice so I have no idea, but maybe you could customize the eat animation to make a slingshot or a big kamehameha ball in front of you.
@Pleeze
@Pleeze 8 ай бұрын
Idk how I got here but I enjoyed the video, not that I'll ever do anything with this knowledge.
@Nicky_T
@Nicky_T 8 ай бұрын
Hell yeah. Makes me want to get back into datapack coding
@IkaSternenlicht
@IkaSternenlicht 8 ай бұрын
Looks like I'll have to update some of my datapacks to 1.20.5 when I get the chance. The changes to crafting items and right click detection actually perfectly solve problems I had with both of my current datapacks, crafting broke in one due to multiplayer quirks with Knowledge Book based crafting and the other added custom swords that needed right click detection which was only possible with a carrot on a stick and warped fungus on a stick which can't have their attack speed changed. The latter actually could be improved further with wind charges (once they get added of course) since I need a dash ability and teleporting the player forward is a little jittery though it gets the job done.
@conure512
@conure512 8 ай бұрын
This update really did add a ton of new capabilities! Though I will say, it IS possible to change the attack speed of the carrot/fungus... you just have to remember that a player's inherent attack speed is 4, so the weapon needs to have NEGATIVE modifiers (swords have an attack speed of 1.6, so the modifier would have to add -2.4).
@IkaSternenlicht
@IkaSternenlicht 8 ай бұрын
@@conure512 Noted. I might have to reformat some things for 1.20.5+ anyway looking at the changelogs but it should make things work a bit better.
@quazarinn
@quazarinn 8 ай бұрын
As a bedrock player i see this as an absolute win
@apersimmon
@apersimmon 8 ай бұрын
You could change the player's base speed attribute when the item is being used then reset the attribute when the player is no longer right clicking. that way the play could walk at the same speed regardless of if they are useing the spell, to be clear i mean player attribute not speed effect.
@conure512
@conure512 8 ай бұрын
Changing speed would also mess with the player's FOV, because eating slows you down WITHOUT changing your FOV. So, still not a perfect solution lol
@apersimmon
@apersimmon 8 ай бұрын
@@conure512 It my not be perfect but it still could be a be needed for some niche, it may be desired for some use case. An example could be for performance or wanting to change the fov for example a rapid fire bow that increases the players fov to make it feel "manic".
@RubyPiec
@RubyPiec 8 ай бұрын
FOOD??? thats insane
@xLTxFire
@xLTxFire 8 ай бұрын
I actually didn't know about the food thing. I need to keep up with things better.
@skeletorthebest7204
@skeletorthebest7204 8 ай бұрын
I like to use the warped fungus on a stick
@firstnamelastname442
@firstnamelastname442 8 ай бұрын
why don’t they add a new item component that contains the name of a function to run when the item is right clicked and another for left click?
@maxanimator9547
@maxanimator9547 8 ай бұрын
What's wrong with interactions ?
@erd_nasird
@erd_nasird 8 ай бұрын
For the movement speed, maybe you could probaby attribute modifier the player with some movement speed to counter them and remove the modifier when they are done using the item.
@Pillow_
@Pillow_ 8 ай бұрын
Huh, very interesting! I should really get into datapacks
@_chadrose
@_chadrose 8 ай бұрын
Thanks for all your hard work! I think this should be the new standard for datapacks to come! but man, I have to learn to get used to thinking based on granting/revoking advancements because I feel like it's slightly less intuitive compared to actual coding, but hey this feels so much more optimised though!
@nati0598
@nati0598 8 ай бұрын
Hell yeah! It was only a matter of time before the recent changes mojang made were used for something amazing.
@SpiritOfTheGalaxy143
@SpiritOfTheGalaxy143 8 ай бұрын
Congrats @satwr on getting in a video!
@Kirisame_Soup
@Kirisame_Soup 8 ай бұрын
Or, even simpler, you can schedule a function on the advancement ticking to revoke it. I think it should do the trick
@Omena0
@Omena0 8 ай бұрын
When interaction entity
@jess648
@jess648 8 ай бұрын
with the component system evolving mojang is probably gonna add another way to do this by accident
@DukkyMC
@DukkyMC 8 ай бұрын
You can also just use the schedule command instead of making a whole timer to remove the advancement, but nice technique!
@conure512
@conure512 8 ай бұрын
Schedule causes issues in multiplayer (no way to determine who called it) and also things can break if the player disconnects during the schedule!
@DukkyMC
@DukkyMC 8 ай бұрын
@@conure512 makes sense. could probably force a uuid check
@Raccoon5
@Raccoon5 8 ай бұрын
Can you counteract the slowdown using speed potion effect? Maybe you could find optimal level of the effect to have normal movement even during right click (except maybe the FOV shift, but that can be disabled in the video settings)
Bedrock. Why?!
22:37
FundyLIVE
Рет қаралды 874 М.
Enceinte et en Bazard: Les Chroniques du Nettoyage ! 🚽✨
00:21
Two More French
Рет қаралды 42 МЛН
Right Click Detection just got 10x better
7:29
Conure
Рет қаралды 15 М.
It Turns Out, Minecraft Can Beat Itself
24:28
PippenFTS
Рет қаралды 1,4 МЛН
Trying to Fix Minecraft's Biggest Scam
16:04
HellCastle & Tylerrrr
Рет қаралды 208 М.
Is 8-Bit Minecraft Possible?
12:58
Inkbox
Рет қаралды 1,4 МЛН
Minecraft's New Update is Crazy!
17:10
mysticat
Рет қаралды 745 М.
Enchanting: Minecraft's Worst System
27:14
FishStickOnAStick - Gaming
Рет қаралды 156 М.
10 Ancient Minecraft Modpacks You Forgot About
15:13
Paladin Ryan
Рет қаралды 545 М.
The Best Mod Developer You’ve Never Heard of
17:26
XayXay
Рет қаралды 725 М.
Why Your Datapack Broke in 1.21
10:57
Conure
Рет қаралды 6 М.
So I got access to Minecraft: China Edition...
15:44
Fundy
Рет қаралды 2,4 МЛН