• 0

    posted a message on [Solved] Command Error With Book?

    So, on my Minigame Server, I have a book of teleports, which uses this long command:



    /replaceitem entity @a hotbar.8 written_book{pages:["[\"\",{\"text\":\"FLIPSIDE MINIGAME\",\"bold\":true,\"color\":\"green\"},{\"text\":\"\\n\",\"color\":\"reset\"},{\"text\":\" \",\"color\":\"white\"},{\"text\":\"SERVER\",\"bold\":true,\"color\":\"green\"},{\"text\":\"\\n\\n \",\"color\":\"reset\"},{\"text\":\"Lobby\",\"bold\":true,\"color\":\"blue\",\"clickEvent\":{\"action\":\"run_command\",\"value\":\"/tp @p 1970 102 1960\"}},{\"text\":\"\\n\\n\",\"color\":\"reset\"},{\"text\":\" \",\"color\":\"black\"},{\"text\":\"Cosmetics\",\"bold\":true,\"color\":\"gold\",\"clickEvent\":{\"action\":\"run_command\",\"value\":\"/tp @p 1970 102 1950\"}},{\"text\":\"\\n\\n\",\"color\":\"reset\"},{\"text\":\" \",\"color\":\"red\"},{\"text\":\"Kit PvP\",\"bold\":true,\"color\":\"red\",\"clickEvent\":{\"action\":\"run_command\",\"value\":\"/tp @p 1970 102 1954\"}},{\"text\":\" \\n\\n \",\"bold\":true,\"color\":\"red\"},{\"text\":\"Spleef\",\"bold\":true,\"color\":\"gray\",\"clickEvent\":{\"action\":\"run_command\",\"value\":\"/tp @p 1970 102 1946\"}},{\"text\":\" \",\"bold\":true,\"color\":\"red\"},{\"text\":\"\\n\\n\",\"color\":\"reset\"},{\"text\":\" \",\"color\":\"black\"},{\"text\":\"(More Coming)\",\"bold\":true,\"color\":\"black\"}]"],title:"Teleports - Right Click",author:"F.M.S"}


    Anyway, this works fine for me and my friends, if everyone is op(p?)ed. However, my brother just joined with a new account, and whatever he does, the book doesn't work. He can click the command, and the command triggers, but it just says there's an error at the end of the tp commands (e.g. /tp @p 1970 102 1954<-- [HERE]).


    1. He is already op(p?)ed.

    2. All the commands are within the spawn chunks, and I've teleported him there already just in case he hadn't loaded it.

    3. The commands work for everyone else.


    I will be grateful for any help!

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Custom Teleport Back and Forth?

    Thanks to everyone who helped with this! It works :D!

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Custom Teleport Back and Forth?

    I've already got the armor stands tagged uniquely, with a score, as each player has a unique score (given to them when they first join), the problem I have is getting a command that teleports the player to an armor stand with that same score, no matter what that score is.

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Custom Teleport Back and Forth?

    That's not the issue I have, though thanks m8 (that's exactly what I have already, lol). The issue is teleporting the player back to the correct armor stand that they tped from originally.


    It would work easy if it was singleplayer, but as it's multiplayer, it'll be hard to not get mixed up.

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Every Single Scoreboard Wiped?

    So I am running a minigame server, which I've been constantly working on, just for me and my friends.


    It's entirely hosted on my PC, and the network.


    And twice during its history, every single scoreboard and tag has been wiped, apparently for no reason, and I can't find out why.


    I generally backup the server, but I've forgotten to for about a month, so I've been set really far back :(.


    Just wondering if anyone would have had a reason as to why this may have happened?


    NOTE: sorry if this is the wrong place...

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Custom Teleport Back and Forth?

    Okay, well I've found somewhat of an issue around this.


    When a player first joins the world, they are selected with @a[tag=!NotNew], meaning they don't have the tag NotNew. Anyway, I did this:



    /scoreboard players operation @a[tag=!NotNew] PlayerNumber = @e[name=PlayerNumber,limit=1] PlayerNumber


    ^ This gives the players without the NotNew tag a score that equals the score of an armorstand called PlayerNumber.



    /scoreboard players add @a[tag=!NotNew] PlayerNumber 1


    ^ I then add one onto whatever score the player has, which is whatever the armorstand has.



    /scoreboard players operation @e[name=PlayerNumber,limit=1] PlayerNumber = @a[tag=!NotNew] PlayerNumber


    ^ I then make the armorstand's score equal to that of the player, meaning it has increased by one.


    Then I give the player the tag NotNew.


    Anyway, the purpose of this, is that each new player that joins gets given a score that is one higher than the armorstand, then the armorstand's score is made equal to that of the player. This means that each time someone new joins, they get given a different, and higher score.


    So, this means that each player gets a unique score, without having to specify who each player is, etc.


    That's the first part.


    Then, the second part is the part I'm having issues with.


    The players then have an item in the top corner of their inventory, which when they chuck out, it activates a chain of commands.


    What I want this to do (and am halfway through doing) is, when they chuck out the item, it summons an armor stand at the player, and then gives the armor stand a score equal to that of the player.


    Then it teleports the player to the shop.


    Then, when the player is done shopping, I want them to press a BACK button, which teleports them back to the armor stand.


    My two problems are this:


    1. How can I teleport a player with a certain score to an armor stand that has that score. However, I don't want to specify 'player with a score of 2' gets tped to 'entity with a score of 2', or 3, or whatever.


    If this doesn't work, I guess I'll just have to make 30+ commands tping player with score of 1, player with score of 2, etc...


    2. Seeing as this world I'm building is a floating island world, I made the armor stand that gets summoned affected by gravity, so it falls until it touches the ground.


    How can I do this: Make it so that if the armor stand doesn't exist (has fallen into the void, or been killed some other way) tell the player that there is an error, and tp them to the default spawn?


    Any help is appreciated!

    Posted in: Commands, Command Blocks and Functions
  • 1

    posted a message on Im New to commands can you show me some please 😁

    Why don't you just try experimenting, or look up the command page on minecraft wiki?

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Check if armor stand exists [SOLVED]

    just do...



    /execute unless @e[tag=ChunkLoader] run <whatever your summon command is, I assume you have one>

    Hope that helps!


    (If you want a command for summoning the armor stand as well, just tell me)

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Custom Teleport Back and Forth?

    Well, is it possible to do it with scores? Idk, something like if a player exists (or armor stand) that has a score of, say, 10, it makes it 11 for you?


    I will try it out when I get time, just wondering if that could work...

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Custom Teleport Back and Forth?

    So, I have a server world I'm working on, where everyone has a item in their inventory, and if they chuck it out, it teleports them to the XP shop of the world.


    There they can do whatever they want (buy stuff etc), and then I want them to press a button that teleports them back to where they were.


    So, I imagine I'd summon an armor stand at the player who chucks out the item, and then teleport them back to it. The thing is, I want each player to NOT get mixed up with other player's armor stands...


    So how can I do this so that each player gets a unique tag, or score, or just each armour stand is unique to each player (without specifying who each player is, or setting up 20 different things?)

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Mechanization: A Technology Based Datapack

    Hey dude, are you going to add this to minecraftmaps.com? they just added a section for datapacks....


    Looks amazing btw!

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Limiting Player's Coordinates?
    Quote from YMbrothers»

    Wait, if all you need is to stay at the same y-coord, doesn't levitation lvl 255 solve the case? If you don't like the fact that taking damage makes the players shoot right up, you can do the following:

    1. Don't let them take damage.

    2. summon the same armor stand before hand. Except you do the following:

    a) The armor stand simply teleports to the player

    B) If the player takes damage (nbt=!{HurtTime:0s}), stop teleporting the armor stand to the player. Instead, make a command to do the reverse (i.e. player teleports to the armor stand). It might make the player go a little bit higher, but better than not.

    c) If the player is still moving up after his/her/its HurtTime reaches 0, change it into some sort of cooldown system, where players cannot move for like 3 seconds if they take damage.


    Now does that shed any light?


    That looks pretty good! I'll try it when I can!

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Target only items without a specific NBT tag with /clear (1.13)

    Could you select it by name, and then give the new pickaxe a different name? Whether it's just a slight adjustment, or a different colour, or something that a default stone pickaxe doesn't have?

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Limiting Player's Coordinates?
    Quote from YMbrothers»

    I'll split your comment into 2 parts.


    1) Does it mean as soon as it's activated, you're stuck there? (btw, sorry bout that. Now you know that u can just untag the armor stand or simply /kill it)


    2) You cannot use /execute store on players. But you can always make another armor stand and make the player teleport. Though I doubt it'll solve the issue.



    1. Nah it was fine to get rid of. I just wasn't expecting it.

    2. :(. I guess I"ll have to think of something else. Thx though for it all :).


    EDIT: The only real thing I wanted to do was make anyone wearing a certain helmet (I've got the selector part handled) stay at a certain Y coordinate.


    I've got everything else for the moment, will play around with other solutions and come back if I need anything else...


    Thanks for the help guys! (Altho it's not really solved...)

    Posted in: Commands, Command Blocks and Functions
  • 0

    posted a message on Limiting Player's Coordinates?

    Okay. So I've tested it, and the first two work excellently, but the third (not including the crouch) that makes me stay at its Y coordinates just teleports me there. It doesn't just do the Y coordinate, but teleports me to the armor stand. (It was quite a conundrum getting out of that!). \


    What I'm wondering is, the first two appear to copy my X and Z coordinates and apply them to the armor stand. Could I not reverse this, and copy the armor stand's Y coordinate and copy it to me?

    Posted in: Commands, Command Blocks and Functions
  • To post a comment, please or register a new account.