How to use MACRO COMMANDS in 5 minutes!

แชร์
ฝัง
  • เผยแพร่เมื่อ 24 ธ.ค. 2024

ความคิดเห็น • 66

  • @Craiy
    @Craiy  ปีที่แล้ว +6

    I should mention that you could make the last example much shorter by just using the size parameter in combination with relative coordinates like:
    $execute positioned 125 66 111 run fill ~ ~ ~ ~$(size) ~$(size) ~$(size)
    That would make the scores pretty much obsolete, but then again, I think the example I showed was good to give you an impression of how you could use these parameters for calculations ^^

  • @coledoe1030
    @coledoe1030 ปีที่แล้ว +3

    this seems super useful, but I’m gonna have to watch this video like 30 times to actually get it lol

  • @L-i-o-n
    @L-i-o-n ปีที่แล้ว +1

    4:10 Is tutorial:cube another function and what do I have to written down in it? Thanks!

    • @Craiy
      @Craiy  ปีที่แล้ว

      Lol I havent noticed that until now. Apparently I have renamed the function to fill_cube_macro which I show directly after. Sorry for the confusion

  • @Talon2863
    @Talon2863 ปีที่แล้ว +5

    Super helpful tutorial. I really liked the way you progressed through the explanation. It did take me a while to get the connection between the storage and macro parameters, but overall really helpful. Thanks!

    • @Craiy
      @Craiy  ปีที่แล้ว

      Yeah there isnt really a connection. We just write data in the storage and can use it to call a function later on

    • @Kabukkafa
      @Kabukkafa หลายเดือนก่อน +1

      no way bro why are you this small you are soo underrated

  • @bentri7964
    @bentri7964 ปีที่แล้ว

    Thank You so much for this tutorial! yesterday I spent hours failing to use them but today I finished what I was trying to do in just 5 minutes!

  • @Equal-zzz
    @Equal-zzz ปีที่แล้ว +5

    Technically, they added variables, which weren't a thing for decades

    • @Craiy
      @Craiy  ปีที่แล้ว +1

      Yup and its insane. Everything will change now. You can store an entire command in a macro and run it

  • @Sauliusram
    @Sauliusram 4 หลายเดือนก่อน +2

    This video is exactly what I need! I have a question: can you directly integrate the scoredboeard into a function? I wrote like this, but it does't work:
    "/function camp:player1/teleport_player_after_death {X:{"score":"PlayerX"}, Y:{"score":"PlayerY", Z:{"score":"PlayerZ"}}}"

    • @Matttt606
      @Matttt606 3 หลายเดือนก่อน

      I wish 😭

  • @BlueCommander
    @BlueCommander ปีที่แล้ว

    Wow this is such a cool command! I can't even begin to imagine how much simpler data pack code is going to become because of this!

    • @Craiy
      @Craiy  ปีที่แล้ว

      Yup it changes everything! Btw good to see you m8 ❤

  • @The_Canadiac
    @The_Canadiac ปีที่แล้ว +1

    ANY COMMAND IS NOW DYNAMIC THATS SO USEFULL

  • @Quillbee
    @Quillbee ปีที่แล้ว

    This is super useful, thank you!

  • @eyes_of_devil
    @eyes_of_devil ปีที่แล้ว +1

    You can update a endermorph .for doge and new power and new enderman or new boss

  • @qwerty3805
    @qwerty3805 ปีที่แล้ว +1

    Macro command r so useful as it allows everything to be dynamic

  • @myToasterDied
    @myToasterDied ปีที่แล้ว

    We need more videos like this from you

    • @Craiy
      @Craiy  ปีที่แล้ว

      Thanks! When I made the last tutorial, I actually planned to make a whole series about datapack basics. However I quickly noticed that it was kinda a boring job to talk about scoreboards or basic execute commands, so Ill likely only do tutorials whenever I think the topic might be interesting

  • @tpcoffline
    @tpcoffline ปีที่แล้ว

    You explained it in a way that everyone can understand. You are great!

    • @Craiy
      @Craiy  ปีที่แล้ว +1

      Thank you! Thats really nice to hear as that was my goal with this video :)

  • @eyes_of_devil
    @eyes_of_devil ปีที่แล้ว +1

    Can you make a telekinesis power datapack ?

    • @Craiy
      @Craiy  ปีที่แล้ว

      I kinda did already. Have a look at my enderman datapack (or maybe even the gravity gun)
      th-cam.com/video/tkFkxh87-WA/w-d-xo.html

    • @eyes_of_devil
      @eyes_of_devil ปีที่แล้ว

      ​@@Craiyok thanks

    • @eyes_of_devil
      @eyes_of_devil ปีที่แล้ว

      ​@@CraiyBut if you can, make a datapack that gives us elemental powers

    • @Craiy
      @Craiy  ปีที่แล้ว

      @@eyes_of_devil There you go :D
      th-cam.com/video/K-4jZXadzIc/w-d-xo.html

  • @andreaspatsalides1914
    @andreaspatsalides1914 ปีที่แล้ว

    I see your mcfunction file recognizes the new macros in visual studio. What plugin did you use? The current ones are outdated. I'm making a big datapack using macros and having an error every time is so annoying.

    • @Craiy
      @Craiy  ปีที่แล้ว +1

      It doesnt recognize them, I just disabled error checking for this tutorial

  • @Zeplington
    @Zeplington ปีที่แล้ว

    Very well explained, even I was able to understand! 😅 Great video 👍

    • @Craiy
      @Craiy  ปีที่แล้ว +1

      Thanks! :)

  • @MINECRAFTLOVER4000
    @MINECRAFTLOVER4000 ปีที่แล้ว

    cant you add replace at the end of the fill command to not have to clear it first?

    • @Craiy
      @Craiy  ปีที่แล้ว +1

      The reason we replace the full area with air once is because we could shrink it from say a 5x5 cube to a 3x3. The new cube is smaller so we have to subtract a bunch of blocks.
      If the cube wouldnt have the scale feature, then yes you could use replace, but it would be unnecessary and require the block that has to be replaced too

  • @As1anCr4ck3r
    @As1anCr4ck3r หลายเดือนก่อน

    Amazing tutorial but I have only 1 question. How can I get a data value from a NEARBY entity and paste it into a macro command as of 1.21.3?
    EX: Say there is an armor stand with a score value of say 5, how can I paste it executing as a nearby player into BOTH OF these selectors?
    $execute as @s if entity @n[type=armor_stand,distance=..3,scores={test=$(score)}] run damage @s 5 player_attack by @p[scores={test=$(score}]

    • @Craiy
      @Craiy  หลายเดือนก่อน +1

      Create a storage for it and use it like that:
      /execute store result data storage tutorial:path score int 1 run scoreboard players get @n[type=armor_stand] score
      /function tutorial:macro with tutorial:path

    • @As1anCr4ck3r
      @As1anCr4ck3r หลายเดือนก่อน

      @@Craiy tysm!!!

  • @evillizard9323
    @evillizard9323 ปีที่แล้ว

    In your botw data pack, are you planning on adding Kass at any point?

    • @Craiy
      @Craiy  ปีที่แล้ว

      Hmm actually not planned yet. I mean what would kass do?

    • @evillizard9323
      @evillizard9323 ปีที่แล้ว

      @@Craiy I've been trying to think about that. If you plan on adding shrines, he could point you in the direction of the nearest one. Otherwise, you could buy music related blocks and items from him.

  • @nandorboda8049
    @nandorboda8049 ปีที่แล้ว

    Yea, one of the best command system update ever.

  • @johnwopie3795
    @johnwopie3795 ปีที่แล้ว

    Can you pls make the portal gun and the gravity gun datapacks for the 1.20.1 version?

    • @Craiy
      @Craiy  ปีที่แล้ว

      Did you try it? Because I didnt for quite some time, but I think those should work at 1.20.1

    • @johnwopie3795
      @johnwopie3795 ปีที่แล้ว

      @@Craiy no i doesnt try it,
      Thank you

  • @styrus3164
    @styrus3164 ปีที่แล้ว

    very helpful video

  • @jadesprite
    @jadesprite 8 หลายเดือนก่อน

    I can't seem to pass a compound during `execute if` in 1.20.4... :(
    For example:
    /execute if function tz:xpeffects/eff/str_test {amplifier:1} run say Success!
    str_test is only:
    $return run effect give @p minecraft:strength 15 $(amplifier)
    Doing this still works entirely as exected though:
    /function tz:xpeffects/eff/str_test {amplifier: 3}

    • @jadesprite
      @jadesprite 8 หลายเดือนก่อน

      Ok... I got something that works...
      ## Perform some checks above this line, like checking if we have required inventory or levels
      data remove storage tz:xpeffects BuffSuccess
      execute store success storage tz:xpeffects BuffSuccess int 1 run function tz:xpeffects/eff/str_test {amplifier:1}
      execute if data storage tz:xpeffects {BuffSuccess:0} run function tz:xpeffects/err/stronger_effect_active
      execute if data storage tz:xpeffects {BuffSuccess:0} run return fail
      ## Do more stuff now that we have completed all the checks AND applied the buff, like remove required items and levels

  • @ludev5743
    @ludev5743 ปีที่แล้ว

    what editor are you using?

    • @Craiy
      @Craiy  ปีที่แล้ว

      Vscode

    • @ludev5743
      @ludev5743 ปีที่แล้ว

      @@Craiy how did you get the language support for the datapack language. Mine doesnt seem to work with the new macros

    • @Craiy
      @Craiy  ปีที่แล้ว

      @@ludev5743 Yeh I disabled error checking for this tutorial

    • @ludev5743
      @ludev5743 ปีที่แล้ว

      @@Craiy k, thanks man!

  • @CryptedCoder
    @CryptedCoder ปีที่แล้ว

    is there a way i can make it run every frame?

    • @Craiy
      @Craiy  ปีที่แล้ว

      Sadly only works on a tick basis, so 20 times a second. You can't really get higher than that

  • @Equal-zzz
    @Equal-zzz ปีที่แล้ว

    Easy looping through arrays goes brrrr

  • @FunkyToc
    @FunkyToc ปีที่แล้ว

    Nice video!
    Honestly, I never use it... The data storage case you just show is pretty much the only interesting thing we can do with it, but you can skip it 99% of the time sadly :/
    I see the potential of this first real "variable", but it is not usable by public player trhough a /trigger or anything else, meaning this is mainly a dev tool.
    Cool, but incomplete, way to rare usecases.

    • @Craiy
      @Craiy  ปีที่แล้ว +1

      Yeah it does make a lot of things shorter when you use it right, but I agree the way it currently is, I don't use it as much as I thought I would.
      If you think outside the box tho, there are a couple of new things that weren't previously possible, like the last example I showed

    • @FunkyToc
      @FunkyToc ปีที่แล้ว

      @@Craiy hum... possibly interessting usecases with the /return... got to work on this ^^

  • @Saltkoenigin
    @Saltkoenigin ปีที่แล้ว

    Informatik Student😂

    • @Craiy
      @Craiy  ปีที่แล้ว

      ?

    • @Saltkoenigin
      @Saltkoenigin ปีที่แล้ว

      @@Craiy du kennst dich da aus. Deswegen der Witz

  • @20_NickName_20
    @20_NickName_20 7 หลายเดือนก่อน

    now we only have to wait until we have normal number operations...

    • @Craiy
      @Craiy  7 หลายเดือนก่อน +1

      Imagine multiplying in less than 3 lines 😱

  • @L-i-o-n
    @L-i-o-n ปีที่แล้ว +1

    As soon as I typ "$" in my tp_macro.mcfunction file in visual studio code it shows me an underlined red line. DO you know why? @CRAIY

    • @Craiy
      @Craiy  ปีที่แล้ว +1

      Yes, update your mcfunction addons. This is a new thing so its not recognized by every addon/old versions

  • @tpcoffline
    @tpcoffline ปีที่แล้ว

    Hey, I told you before that you explained it very well, can you also explain how to raycast?

  • @myToasterDied
    @myToasterDied ปีที่แล้ว

    cool