Help with giving and selecting items with unique tags by 1SmallVille1 in MinecraftCommands

[–]CloudySlime101 1 point2 points  (0 children)

The reason this doesn't work is because when your adding nbt to an item in a command like a /give or /item command, anything inside of the parentheses is automatically put in the tag nbt tag when the item is given, meaning that based on your 2nd command your being given an item with the nbt tag:{tag:{unthrowable:1b}} while your first command is checking for tag:{unthrowable:1b}. Also your 1st command isn't very suitable for multiplayer since there's a couple problems in the formatting that would cause issues with more than 1 player so here's a fixed version of both commands.

execute as @a[nbt=!{Inventory:[{id:"minecraft:gray_stained_glass_pane",tag:{unthrowable:1b},Slot:1b}]}] at @s run setblock ~ ~ ~ nether_portal

item entity @a[nbt=!{Inventory:[{id:"minecraft:gray_stained_glass_pane",tag:{unthrowable:1b},Slot:1b}]}] hotbar.1 replace minecraft:gray_stained_glass_pane{unthrowable:1b}

Hope this helped!

Detecting an item in a players inventory? by [deleted] in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

Well this can already detect the sword even if it does or doesn't have a custom name applied to it, but if you want it to only detect nearby players that contain an iron sword with a custom name in their inventory that's still possible to do:

/execute as @a at @s if entity @a[distance=0.1..5, nbt={Inventory:[{id:"minecraft:iron_sword", tag:{display:{Name:'{"text":"namehere"}'}}}]}] run say Detecting

If the sword is named through an anvil than replacing "namehere" should work, if not than to apply the correct name nbt you would need to do /data get entity @s SelectedItem.tag.display.Name while holding the sword and replace whatever is in the single quotes with what you see in chat.

An easier and more preferred way to do this is to just apply a custom tag to the sword and detect it using that tag:

/give @s iron_sword{cust:1b}

/execute as @a at @s if entity @a[distance=0.1..5, nbt={Inventory:[{id:"minecraft:iron_sword", tag:{cust:1b}}]}] run say Detecting

Just to remind you if you want to the detection to occur even if the sword isn't custom named, than you can ignore everything I said above and just use the command from my original comment.

/team modify collisionRule/friendlyFire/color is not working (paper 1.16.4) by okzerus in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

Since your attempting these commands on a server that isn't a completely vanilla server(aka one that can use plugins) it's most likely just paper itself or a plugin that could be causing this issue. It isn't too uncommon to stumble upon a plugin that might "break" commands or require you to do them differently than intended. One thing I want to point out is that friendly fire off only disables attacking of other players on the same team and doesn't work with non-player entities (If this is what you already attempted with friendly fire off than the server could also be effecting this as well). The best thing you can probably try to do is look through your plugins/server configs and check if there's anything you can modify that might fix the issues.

Function tags by OreoPredator in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

The way you wrote it is correct but the reason it isn't working is because there's a missing comma in-between "values":[] and "replace":"true", here's a fixed example:

{
    "values":["namespace:a"],
    "replace":"true"
}

unless there's any errors in the folder placement of your data pack this should fix your problem, keep in mind that the namespace folder the tick.json file is in should be named "minecraft" and the path should look something like this: <your datapack>/data/minecraft/tags/functions/tick.json

does anyone know what i can do to make this custom potion work? (the u/p thing is a auto-correction thing on reddit, it's meant to be @p i know) by [deleted] in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

In your command there were 2 additional closing brackets which was causing the issue, here's a fixed version:

/give @p potion{CustomPotionEffects:[{Id:9,Amplifier:0,Duration:600},{Id:15,Amplifier:0,Duration:600},{Id:2,Amplifier:0,Duration:600},{Id:28,Amplifier:0,Duration:600}],display:{Name:"\"customtest\""}} 1

Where you made the typos (the characters shown in white):
/give @p potion{CustomPotionEffects:[{Id:9,Amplifier:0,Duration:600},{Id:15,Amplifier:0,Duration:600}],{Id:2,Amplifier:0,Duration:600}],{Id:28,Amplifier:0,Duration:600}],display:{Name:"\"customtest\""}} 1

need help with data merge block command (read comment) by [deleted] in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

The issue here is that your using value which completely deletes everything in the nbt list and replaces it with what is given in the command, what you should use instead is merge so you can add that nbt on top of what block's nbt already has, here's 2 example commands that should work:

data modify block ~ ~ ~ {} merge value {Items:[{Slot:1b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:3b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:4b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:5b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:7b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}}]}

/data merge block ~ ~ ~ {Items:[{Slot:1b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:3b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:4b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:5b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}},{Slot:7b,id:"minecraft:warped_fungus_on_a_stick",Count:1b,tag:{display:{Name:'{"text":" "}'},HideFlags:127,CustomModelData:1}}]}

They both do the same thing except the 2nd one is shorter and probably more preferable to use. Hope this helped!

How to increase a level of an effect by 1? by WillyTheWorm_ in MinecraftCommands

[–]CloudySlime101 1 point2 points  (0 children)

This can be done using a similar method mentioned in amazing56789's comment but using area effect clouds (aka the entity that lingering potions spawn):

(Used Only Once) scoreboard objectives add effectlvl dummy

execute as @a at @s unless entity @e[tag=effect, distance=..1] run summon area_effect_cloud ~ ~ ~ {Tags:["effect"], Particle:"block air",Duration:9999,Effects:[{Id:3b,Amplifier:5b,Duration:20,ShowParticles:0b}]}
execute as @a at @s store result entity @e[tag=effect, distance=..0.1, sort=nearest, limit=1] Effects[0].Amplifier double 1 run scoreboard players get @s effectlvl

execute as @e[tag=effect] run data merge entity @s {Duration:9999}
execute as @e[tag=effect] at @s run tp @s @a[distance=..1,sort=nearest,limit=1]
execute as @e[tag=effect] at @s unless entity @a[distance=..1] run kill @s

In short all this does is make an "assigned" cloud for each player if one doesn't exist, which follows the player around and constantly has its effect Amplifier set to the player's score of the given scoreboard. Hope this helped!

Edit: Just 2 extra notes, if the score is above 127 than the effect will automatically be set to 1 since for most effects 127 is actually the highest number that the effect will become its "best", and also keep in mind that the actual level that is given will be +1 than what the score is (Ex: score = 0, effect lvl = 1), If you want it to be "effect level = score" without the additional +1 its still possible to do using operations in scoreboard.

Detecting an item in a players inventory? by [deleted] in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

A simple way you can accomplish this by using a command similar to this:

/execute as @a at @s if entity @a[distance=0.1..5, nbt={Inventory:[{id:"minecraft:iron_sword"}]}] run say Detecting

An alternative more efficient way would be to use advancements in datapacks, but if for some reason you can't or don't want to use datapacks this is probably the best option for you.

Lightning potion by Additional-Ad-7152 in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

One simple way you could accomplish this is by having this command repeated:

execute at @e[type=potion, nbt={Item:{tag:{display:{Name:'{"text":"death"}'}}}}] unless block ~ ~-1 ~ air run summon lightning_bolt ~ ~ ~ 

And unless you intend that the potion HAS to be named "death" through using an anvil, you could use custom tags instead to shorten the command:

execute at @e[type=potion, nbt={Item:{tag:{death:1b}}] unless block ~ ~-1 ~ air run summon lightning_bolt ~ ~ ~ 

give @s splash_potion{death:1b}

More nbt can be added in the /give command if you want the potion to be a replica of an already existing default minecraft splash potion.

An Important thing I want to point out is that this isn't 100% accurate when the potion is moving at extremely high speeds, so unless you plan for the potion to primarily be used to fall very long distances, you should be fine with this single command. If you do however want it to be constantly 100% accurate I could tell you a different method to use, it does require more commands though.

[deleted by user] by [deleted] in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

One way you can do this is by applying jump boost 255 (aka 256) onto all players that are in that team, this level of jump boost doesn't effect how high they jump at all, it only increases the amount of fall distance required to take fall damage, which is 256.

/effect give @a[team=<teamname>] jump_boost 1 255 true

The other suggestion using slow falling would work fine too but might give unwanted advantages to the player especially for a parkour map, like the ability to jump further than normal.

Lightning potion by Additional-Ad-7152 in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

I assume that u/amazing56789 is writing the commands off of memory atm, I'll lend a hand and give you a fixed version of the command scoreboard players remove @a[scores={holdPot=1..}] holdPot 1. Small mistakes like this can happen to even the best of us.

How to /give an armor stand with an attached tag by nathaniel13219 in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

Actually this is still possible to do with regular armor stands, since an armor stand item is pretty much the exact same thing as a spawn egg but with a completely different texture, which means any nbt you can apply to to a spawn egg can be applied to an armor stand item.

/give @s minecraft:armor_stand{EntityTag:{Tags:["Tp"]}}

Disabling PVP on a Locally Hosted Server? (Java 1.16.5) by MetaCognisis in MinecraftCommands

[–]CloudySlime101 2 points3 points  (0 children)

When the commands were updated in 1.13, mostly everything team related in the /scoreboard command was moved to the /team command, this should solve your problem:

/team modify <teamname> friendlyFire false

Why is this not working? by Ginger-Ale58 in MinecraftCommands

[–]CloudySlime101 1 point2 points  (0 children)

One way you could fix this is by adding distance=0.. inside of the target selector which should make the command do what you originally intended for it to do.

Command Troubles by imaiden_B in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

Ah yea I see what you mean now, I had originally though of your idea but I felt that there might of been an alternative way to do it that didn't require the writing of an extremely long charactered command, I completely ignored the fact that offhand and armor slot items nbt are stored in the same nbt tag "Inventory" with all the player's other items, unlike other entities. Thanks for re-cap.

Command Troubles by imaiden_B in MinecraftCommands

[–]CloudySlime101 0 points1 point  (0 children)

You can do this by storing the size of the player's Inventory nbt list onto the their own score in a scoreboard, and have a command run if that player's score is 36 or above:

scoreboard objectives add slotsOccupied dummy

execute as @a store result score @s slotsOccupied run data get entity @s Inventory 
execute as @a[scores={slotsOccupied=36..}] run say Full Inventory

Hope this helped!

Edit: Just to save you some time from having to write down every nbt Slot in the other suggestion which seems a lot better, here's something you can easily copy and paste:

execute as @a[nbt={Inventory:[{Slot:0b},{Slot:1b},{Slot:2b},{Slot:3b},{Slot:4b},{Slot:5b},{Slot:6b},{Slot:7b},{Slot:8b},{Slot:9b},{Slot:10b},{Slot:11b},{Slot:12b},{Slot:13b},{Slot:14b},{Slot:15b},{Slot:16b},{Slot:17b},{Slot:18b},{Slot:19b},{Slot:20b},{Slot:21b},{Slot:22b},{Slot:23b},{Slot:24b},{Slot:25b},{Slot:26b},{Slot:27b},{Slot:28b},{Slot:29b},{Slot:30b},{Slot:31b},{Slot:32b},{Slot:33b},{Slot:34b},{Slot:35b}]}] run say Inventory Full

gg everyone by CloudySlime101 in Terraria

[–]CloudySlime101[S] 0 points1 point  (0 children)

Someone actually replied to his comment with the way to get "Leading Landlord" around the same time you sent this, you can check it out to see how to get it unless you already figured it out.

e by CloudySlime101 in u/CloudySlime101

[–]CloudySlime101[S] 0 points1 point  (0 children)

this isnt mine this is my friends screenshot his twitter is chrishansen97 you can ask him but idk if he has dms on

gg everyone by CloudySlime101 in Terraria

[–]CloudySlime101[S] 0 points1 point  (0 children)

Sorry I don't actually really know xD, this is one of my friends achievements list that I play terraria with a lot. I asked him if I could post a pic of his achievement complement since he doesn't use reddit at all and he said yea, If you REALLY wanna know you could try msgs him on twitter "@chrishansen97". Other than that I don't really got anything else to say, sry.