Questions tagged [minecraft-commands]

Anything related to the usage of commands, command blocks, and functions in the Minecraft game series. Always use this tag together with the [minecraft-java-edition], [minecraft-bedrock-edition], or [minecraft-education-edition] tag. Include details about the issue you're having (e.g. commands, error messages, screenshots, etc) and what you've tried so far to solve it. If you're building a redstone device without commands, use [minecraft-redstone] instead.

Filter by
Sorted by
Tagged with
-1 votes
3 answers
607 views

Creating a chest with a specific spawn egg inside

I am trying to make a parkour for my server and the prize would be a villager egg but when I use this command to refresh the chest for others it's just an egg that says: "spawn" /summon FallingSand ~ ...
flram's user avatar
  • 1
9 votes
1 answer
10k views

How do I create a villager with custom trade offers?

I'm trying to set up a shop system in a vanilla minecraft realm and villagers seem like the most streamlined method of doing so, however I'd also like to make it so that other players on the server ...
Arraveci's user avatar
2 votes
3 answers
739 views

Minecraft - Executing on an entity is not working

When I put in this command in a command block: /scoreboard players set @e[type=Item] PigProgress 1 {Item:{id:319}} It says: The dataTag does not match for c97c9605-6b59-44e8-bf24-aa2e46c9c746 ...
Chrisdude011's user avatar
4 votes
1 answer
2k views

Variables in Minecraft?

I would have a lot more possibilities if I could add variables to my commands. Is there anyway to do this? I have tried to use armor stands but it requires a command block for every single ...
KenzoEngineer's user avatar
3 votes
1 answer
1k views

Why won't this redstone and command block setup work like the other one?

I'm trying to make an RPG adventure where the player can interact with different stuff. For example, if he walks up to a crafting table, then this text should come up in chat: [Robert:] I wish there ...
Xandawesome's user avatar
2 votes
1 answer
102 views

How do I clear 2 items from my inventory, with one being a specific name?

I am working on my VANILLA Minecraft server right now and I'm in a bit of a struggle. A player can purchase an iron sword called SLAYER Sword, and can also purchase a regular iron sword. A player can ...
SonicScrew12's user avatar
1 vote
2 answers
81k views

Minecraft Bow Command ./give multiple enchants [duplicate]

So I have this one command creation that I want to use. And I am not sure about the syntax. I want to put multiple enchants on my bow. Can you guys help me with my command so that it works? Here is ...
Stevie B.'s user avatar
4 votes
1 answer
10k views

Testing for a player with a certain score finds any player no matter what their score is

I have an objective called ninja, which can either have a score of 1 or 0. The command I am attempting to use is /testfor @p[score_ninja=1] However, the command returns "Found (my username)" rather ...
tkl1234567890's user avatar
4 votes
1 answer
40k views

How do I replace certain blocks? [duplicate]

I was bored on Minecraft, and so I created a Superflat world with villages. Is there any way that I can replace all of the gravel to say... TNT? I felt like being destructive, and I was wondering if ...
Alex's user avatar
  • 49
-1 votes
1 answer
1k views

What's wrong with this command?

So I entered this and it says this all the time Data Tag Parsing Failed: Encountered Multiple Top Tags, Only One Expected And here is the command: /summon Villager ~ ~1 ~ {NoAI:1,Rotation:[45....
KawaiiNina's user avatar
3 votes
1 answer
520 views

Command Blocks and Redstone Comparators

So I am giving Command Blocks a first try and I've found that with the comparator you can make it so it perceives a player is near them (and of course if you use the [r=x] tag. The scenario I am ...
Vynile's user avatar
  • 33
5 votes
1 answer
3k views

Is there a way to determine whether a player is online or offline with command blocks?

I have some redstone circuitry in place (see attached image), involving a hopper clock, command blocks, and the scoreboard. The basic purpose is to play a sound with /playsound, and then once a ...
Connor Mainwaring's user avatar
-1 votes
1 answer
200 views

How to set a command with a comand block? [duplicate]

I want to set a testfor commandblock. This is the command I want in the block: /testforblock 1998 10 657 glass. What is the setblock command to have this in a commandblock?
nathan's user avatar
  • 1
1 vote
2 answers
19k views

What is the command to summon the biggest slime in minecraft?

I want to summon the biggest slime but I forgot how to do it.
DrEnderpearl e's user avatar
0 votes
2 answers
416 views

Vanilla 1.8 detect new player

In vanilla 1.8 using command blocks, is it possible to change a player's spawn point after they first join a server? When a player first joins a server they are in location "A" When they press a ...
Jonathan's user avatar
  • 633
3 votes
2 answers
26k views

How to enable sethome and home on a Vanilla Minecraft Server

I've seen some Vanilla Minecraft servers that use books with a teleport home, set home, and tp to spawn options. I found an app that I can use to build the custom book, but I can't figure out how to ...
theBeaks's user avatar
  • 621
1 vote
1 answer
10k views

Summon 10 Zombies at players position, to all players

There is a way to summon 10 zombies near every player on the map with command blocks twice a day? In the official command wiki, we can read this: To summon 10 creepers at the nearest player's ...
André Maldonado's user avatar
1 vote
1 answer
4k views

How would I test if a player goes below a certain height and kill them if they do?

I'm building a map and I need to keep people from getting to my redstone. I am going to make it so that it can detect them coming down towards it and send them back to spawn if they pass a certain ...
12coder's user avatar
  • 23
2 votes
2 answers
248 views

Why won't this command work? [duplicate]

/summon Villager ~ ~2 ~ {Offers:{Recipes:[{buy:{id:371,Count:15},sell:{id:264,Count:4}} I'm using this as a recycler villager, and I can't get the first trade to work. What's going on?
Lucas Pichette's user avatar
0 votes
1 answer
421 views

Location specific inventory retention in Minecraft

I own a realm that has the "Keep Inventory" rule enabled. (so when one dies, their inventory is not dropped) I'm building a puzzle dungeon that other players can run through but I'd like there to be ...
twicedouble's user avatar
1 vote
1 answer
3k views

Execute or Testfor a named dropped Item?

I have a contraption set up where if I drop a player head named Camera1 (it looked very much like a camera) a clock will find it and replace it with an armor stand that is also wearing the head. It ...
user115048's user avatar
1 vote
1 answer
806 views

Minecraft - Teleport player on spawn

I would like to teleport the player instantly on spawning. I am aware of the /setworldspawn command. I would like them to spawn into a small building. I cannot make the building larger. Thanks for ...
dGRAMOP's user avatar
  • 135
1 vote
1 answer
8k views

Minecraft add player to team based on scoreboard score

I am trying to make a player join a team when their score is a specific number. Example: /scoreboard teams join Rank1 @a[score_ranklvl=1] Basically, if the players level equals a number and only ...
Jon's user avatar
  • 21
2 votes
1 answer
2k views

How do I add up a team's scores?

I am using the /scoreboard command. I have everything working, but I would like not only all the players' individual scores on the sideboard, but also the two teams. I would like them to update ...
dGRAMOP's user avatar
  • 135
0 votes
2 answers
5k views

How do I use /kill to kill Mooshrooms with a specific name and within a certain radius?

I've been working on a machine and require the command to kill all Mooshrooms with a certain name and in a specific radius. I have tried: /kill @e[type=Mooshroom,r=(radius),name=(name)] /kill @e[type=...
APthree's user avatar
  • 323
-1 votes
2 answers
26k views

/time set night and /weather rain are not working

In all of my worlds, whenever I do /time set night it doesn't work, and instead stays daytime. Also once the game reaches the point were it would turn to night it goes back to the start of a day. So ...
riley's user avatar
  • 7
0 votes
2 answers
365 views

CanPlaceOn tag along with display name? (Minecraft) [duplicate]

I want to know how I can use the CanPLaceOn tag along with a display name for a lever. I've tried this: /give @p lever 1 0 {{CanPlaceOn:[log]},{display:{Name:Jungle Key}}} This doesn't work and ...
Xandawesome's user avatar
1 vote
2 answers
2k views

Is there any way to test if a Players inventory is not full in Minecraft

Is there any way to test if a player's inventory is not full (eg. atleast 1 empty slot anywhere in the inventory, not counting Armor Slots) with command blocks and whatnot?
MCCG's user avatar
  • 169
5 votes
4 answers
29k views

How to make a command block chain?

I'm trying to make a chain of command blocks that would change a player's gamemode and then teleport them somewhere from the press of 1 button. I tried connecting them with redstone and also tried ...
Hayden's user avatar
  • 51
2 votes
2 answers
1k views

I need help with this Minecraft Tellraw command, Issue at column 89

This command is still a work in progress, but I am having issues. It gives me an error message when I click "Check Balance" and the error message says: Invalid json: Unterminated string at line 1 ...
DinitriX's user avatar
1 vote
2 answers
2k views

Testfor block with custom name

I'm making "magic blocks": if you are standing on a specific block you get a potion effect like speed, instant health, strength, etc. The only problem is while trying to make it survival ...
Veritas025's user avatar
4 votes
1 answer
1k views

Determine Minecraft item type from entity or inventory?

I have a dropper which can contain, of course, any items. Assuming I can already target this dropper in a command's target selector, how can I determine what item is in the first slot of its inventory ...
IceMetalPunk's user avatar
1 vote
1 answer
223 views

How to clear only unnamed items

The title might be confusing but what I am trying to ask is say that you have two diamonds. One of them is named "Blat". How do I clear only the item that isn't named?
RedPunchRedstone's user avatar
-4 votes
1 answer
5k views

Where does Zexy Zek get the extra commands?

I watch Zexy Zek's trolling videos, and he always uses these new commands such as /nick, /d, /punish, /pt, etc. Is there a mod for these commands? If so, then can anybody tell me where to get it?
Ligit Gaming 5's user avatar
0 votes
1 answer
2k views

Can I spawn ghast fireballs in vanilla minecraft?

I was watching side quest on Youtube, and they summoned a Ghast fireball. I noticed that they then punched it and went back in the opposite direction. Is this possible in Vanilla Minecraft?
Anonymous's user avatar
3 votes
6 answers
106k views

How can I teleport a player to a location relative to another player?

I want to teleport a player to a location relative to another. For example, I might want to teleport Steve so that he's exactly 50 blocks on top of Joe. I can't use /tp, since that will teleport ...
EscraftTH's user avatar
1 vote
2 answers
3k views

Can I /execute a command at players with a certain score?

For a project I'm working on, I want to be able to execute a setblock command at a player with a certain score. I've tried doing /execute @a[score_xp_min=100] -insert command here- but all it says ...
ZestyLimez's user avatar
2 votes
3 answers
3k views

How do I make a Villager Trade a Spawn Egg [duplicate]

I am trying to make a Custom Trade on a villager. I need to make him buy 8 gold nuggets and sell a Cow Spawn Egg. basically you pay 8 nuggets for a Cow Spawner. The ID of the Cow Spawn Egg is 92 but ...
Eisler 485's user avatar
  • 1,005
1 vote
3 answers
3k views

When attempting to teleport a mob to a player I get 'The entity UUID provided is in an invalid format'

I'm trying to make a machine where it teleports a mob with a custom name to a player in a team. When I activate it it says: The entity UUID provided is in an invalid format The command is: /tp @...
Werts World's user avatar
2 votes
1 answer
225 views

Easy way to execute remote admin commands?

So I'm finishing up my survival games map, adding final touches and such, but... I need an easy way to execute remote admin commands, like setting my own gamemode to creative, starting the game, or ...
Shane Smiskol's user avatar
2 votes
1 answer
2k views

Custom Villager Summon Command

I am trying to summon a Villager that buys 64 Planks of any kind and giving you 1 gold nugget I have tried using /summon Villager ~1 ~ ~ {Invulnerable:1,CustomName:Wood_Buyer,Profession:0,Career:1,...
Eisler 485's user avatar
  • 1,005
0 votes
2 answers
650 views

Teleporting a player from one block to another

So the problem I have here is I want to teleport a player standing at 1 34 70 to 273 33 -5. I have tried using a clock with testfor @a [x=1.3,y=34,z=70] hooked up to a tp @p 273 33 -5 but when I go ...
Eisler 485's user avatar
  • 1,005
-1 votes
1 answer
228 views

Need help on /kill command an usage of @e [duplicate]

Hi everybody I need some help with minecraft. I an a command : /kill @e[type=!Player,ArmorStand] and it didn't work What I wanted : A command that kills every entity except ArmorStand and Players. ...
Lord_Starken's user avatar
1 vote
3 answers
6k views

Teleport a player to face an entity?

If I have an entity, is it possible to teleport that player to face the entity without teleporting the player to the entity (Just changing his rotation)? How could I accomplish this?
user avatar
2 votes
1 answer
883 views

How can I display stats like death count using titles?

I'm making a dungeon-crawler adventure map, and at the end I would like the system to tell the player, either within the chat or on screen (using /title) these criteria: Number of deaths Number of ...
SweetDelight's user avatar
0 votes
1 answer
616 views

How do I make a mob riding another mob and make the rider invisible?

I want to have an invisible blaze riding a bat so it looks like a bat is shooting fireballs. If I do /summon blaze ~ ~5 ~ {ActiveEffects:[{Id:14,Amplifier:1,Duration:999999,{Riding:{id:"Bat"}}}]}, it ...
jeffrey1607's user avatar
0 votes
1 answer
301 views

Can I make a redstone clock that detects certain words? [duplicate]

I made a vanilla minecraft server and I made a redstone clock attached to a command block with /testfor that detects players. Can I change the /testfor from detecting players to detecting certain ...
Ligit Gaming 5's user avatar
1 vote
1 answer
823 views

How do I make the comparator work and then stop?

I made a redstone clock that involves a command block with /testfor and a comparator attached to it. Whenever the /testfor works, the comparator turns on, but completely.(meaning it does not turn off ...
John Hickox's user avatar
-4 votes
1 answer
529 views

How do I kill every entity except arrows and players? [duplicate]

I was trying to make a world where arrows, if shot at a player, will destroy items, but keep the player alive. However when I use the command /kill @e[type=!Player], the arrows will be destroyed.
jeffrey1607's user avatar
4 votes
2 answers
4k views

Can you disable the repair cost increasing in Minecraft 1.8?

As you might know, starting with Minecraft 1.8, the repair cost for an item goes up the more it was previously repaired, to the point where the item can no longer be repaired. Is there a way to ...
MrLemon's user avatar
  • 17.4k

1
93 94
95
96 97
103