How to Build an NPC Shop | Minecraft Bedrock Command Block Tutorial | MCPE XBOX PS

แชร์
ฝัง
  • เผยแพร่เมื่อ 6 ก.ค. 2024
  • #minecraft #minecraftbedrock #minecraftcommands
    A single NPC can sell up to 6 items!! & It's super easy to change the payment type or quantity. If you have any questions feel free to ask!! I'll do my best to help you out :D
    Multiplayer Fixes • NPC Shop Part 2 Multip...
    Important FIXES!!!! The CMDS do work as is, but I have noticed some qol fixes since posting this video.
    Adding [r=X] after the /clear @p will prevent it targeting a farther player if the activating player doesn't have the payment. The r= sets a radius limit to the @p, so [r=5 limits the check to 5 blocks away from the CMD block. Example /clear @p [r=8] diamond 0 1
    & for larger than 1 price denominations a player could still activate it with a single diamond. To add a minimum quantity check it will be /clear @p[hasitem = {item=diamond,quantity=2..},r=10] diamond 0 2
    or ... quantity=3..},r=10] diamond 0 3
    & so on. This adds the r=X to prevent targeting father away, as well as adds a check for having a minimum amount of the desired item. ... quantity=2.. the "2.." means more than 2, or "3.." would mean more than 3. It needs to have the two periods after the number to specify "more than"
    Sorry that this was not included in the video!!!!! I didn't know that @p would skip over the closest player if they didn't have the requirements, & I missed that /clear will work even if the play has less than the desired price. The base cmds in the video will still work as long as people don't try to cheat ;]
    Redstone still confusing? Check out this playlist! Let's Learn Redstone • Let's Learn Redstone S...
    Enjoy!!
    & please Like Comment Subscribe & Share with your friends! I really appreciate all support! It makes me happy & will allow me to continue to explore and discover the universe within art & the art within games.
    0:00 NPC shop overview
    1:18 Tutorial Start
    6:03 Adding additional items for sale
    8:24 Alt CMD shop design
    ____________________________________
    Check these out as well!!
    Turn Off Text Spam from CMD Blocks • Turn Off the Text from...
    CMD Block Basic Guide • Command Block Introduc...
    Let's Build A Froggy!!! • How to Build a Frog + ...
    Item KEY Door • Item Key Door Tutorial...
    How to Build a MOB Farm at your base • How to Build a MOB FAR...
    Sniffer Farm Tutorial • Automated Sniffer Farm...
    Tips & Tricks Playlist • Minecraft Tips & Tricks
    2x2 Flush Piston Door Guide • Piston Door Guide Flus...
    3x2 Flush Piston Door Guide • 3x2 Flush Piston Door ...
    Bedrock Tutorials playlist • OmLedu's Bedrock Tutor...
    Redstone Lamp Scoreboards • Redstone Lamp Scoreboa...
    Shuffleable Deck of Playing Cards!! • How to Build A Shuffle...
    Build a Working Basketball Court • Build A Working Basket...
    Digital Painting Timelapse Playlist • Art Timelapses by Kyle...
    ____________________________________
    ____________________________________
    Recorded with Xbox Game Bar & GeForce Overlay
    Edited with DaVinci Resolve
    ____________________________________
    These may not be active but they exist :)
    My steam steamcommunity.com/id/theuniv...
    Artist FB / theuniversewithin
    Minecraft FB / omledu
    ____________________________________
    The skin I use is from the skin pack "UNTAMED"
    by THE LUCKY PETALS check it out! www.minecraft.net/en-us/pdp?i...
  • เกม

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

  • @OmLedu
    @OmLedu  10 หลายเดือนก่อน +2

    Part2 Multiplayer Fixes th-cam.com/video/r7gttz0_2rY/w-d-xo.html
    For multiplayer: on the /clear cmd add [r=10] after the @p to prevent it from retargeting another player if you don't have the payment.
    /clear @p [r=10] diamond 0 1
    For denominations larger than 1 (on the cost of the item) use the following:
    /clear @p[hasitem = {item=diamond,quanitity=2..},r=10] diamond 0 2
    Or ... ,quantity=3..},r=10] diamond 0 3
    For 3, etc etc
    The ... },r=10] Will prevent it from targeting other nearby players if the player who activated the NPC doesn't have the minimum amount of payment.
    Thank you to @Dusks_Base for pointing that out!!

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

      If you don't turn on all experiment. You could do "@initiator" instead @p. @initiator is the player interacting with npc.

  • @LuvWinchesterMen
    @LuvWinchesterMen 10 หลายเดือนก่อน +2

    I love this concept! There is so much you can do with it! But that Battleship game..... OMG!! SO CUTE!!!!

  • @edriemarricle6420
    @edriemarricle6420 10 หลายเดือนก่อน +2

    Great video!! You brought back so much nostalgia with the Battleship for me! I love that so much🤟

  • @Dusks_Base
    @Dusks_Base 10 หลายเดือนก่อน +2

    The /clear command has a max count, so even if you have just one if the items it will succeed. The hasitem filter is much better for this, as you can require a certain amount.

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

      Whoops! Thank you so much for pointing that out!!! Knew i missed something :X

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

    I try this and if you are have not the items it want but someone is possible close to command block then there items well be gone how can i fix this?

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

      Add [r=10] after the @p
      That sets a radius limit of 10 from the cmd block.
      So sorry!!! I thought it would always just target the nearest player :X
      So /clear @p [r=10] diamond 0 1

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

    can you do a tut on how to do multiple pages for NPC dialogue with the dialogue command?

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

      I can def look into it & see what i can find!
      I thiiiiink there is a way to pull up npc dialogue pages.... but i'm not 100% on that. At the very least you could: have the npc activate a series of say/ tell type cmd block to display lots of text for the player, but that wouldn't necessarily allow for multiple answer inputs... But I'll start looking into it right now :D

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

      Okay! I'll need to mess around with it a bit, but at first glace it looks like you can in fact use the /dialogue cmd to accomplish this.
      What I'm thinking is have an npc hidden for each page that you want. Then have the npc the player will interact with have the /dialogue on the buttons, that then target the corresponding hidden npc whose 'page' you want to display next. Should mimic an npc having multiple pages. I'll test a bunch of stuff and get a video made for you :D prolly will take me about a week, but I'll try n put a rush on it ^.^

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

      I'm so glad you ask how to do this XDD It's so cool! XD I'm having fun messing around with it. Just gotta figure out what to do for the video, but shouldn't take me too long

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

    I tried but it takes away my emeralds (I used emeralds) and doesn’t give me item

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

      Double check the /give cmd block. Make sure it's set to "always active" not "needs redstone".
      If it is: check the error log (bottom right box in the cmd block UI) see it it says any syntax errors or anything.
      If it doesn't say anything: double check that the /clear cmd block is pointing at the /give cmd block, & that they are both chain blocks.
      If it still doesn't work let me know & I'll try more to help you out!!

  • @JamesHays-ur2qs
    @JamesHays-ur2qs 2 หลายเดือนก่อน +1

    This same code as ps4 bedrock or whatever?

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

      Yessss :D
      Ps4, xbox, switch, mobile, bedrock all the same :D
      Just not java ;]

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

    here easier:
    give @initiator[hasitem={item=diamond,quantity=9..}] gold_ingot 64
    clear @initiator[hasitem={item=diamond,quantity=9..}] diamond 0 9

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

      :o whaaaa @initiator is a thing!?! Woh, that is epic! I'll definitely check that out!!! Thanks for letting me know