10

I want to give players the effect where snowflakes appear on the side of the screen, their hearts turn blue, and they take constant damage. Any idea how I can do this while the player is outside of powdered snow?

I tried /effect but that didn't work so I checked the NBT data of the player and of a cow using /data, and it seems that the tag that is changed while an entity is in powdered snow are Ticks Frozen. Setting this value to its natural max, 140, repeatedly on a command block did not cause the cow to take damage, and cannot be tested on players due to the way NBT data modification works.

1
  • 4
    Did you try anything yet, if so please mention what you tried.
    – RyugaGod
    Jun 21, 2021 at 3:41

3 Answers 3

1

currently, this is not possible...

...because freezing is not yet (if it will be at all, think the same thing with being on fire) a Status Effect.

...and it likely will not be possible in the near future...

...provided they decide to keep it that way.

currently, and as it may very well be in the future, the only way to give something freezing, as you pointed out, is by modifying the TicksFrozen data tag of an entity. because you can't modify player NBT data without the world being closed and via an external editor, it is not possible to make a player freeze in-game as it stands.

1
  • 1
    As well as the editing of the TicksFrozen being impossible for the player, I couldn't get mobs to take damage at all by setting it. There might be a combination of tags to cause the effect to take place, but that doesn't particularly matter for the non-editable player tags. Hopefully Mojang adds a way to do this in the future.
    – Regnegade
    Jul 2, 2021 at 14:50
0

I have found a work-around with a datapack.

Minecraft Advancements are checked near the beginning of the game tick and Minecraft's function tag tick is run near the end of the game tick. If Advancement sets block to "powder_snow" and function tag tick sets block to "air", technically the block is "powder_snow", but it is rendered as "air". So basically, invisible powder snow.

Create an Advancement that triggers on tick to call a function.

test.json    
{
    "criteria": {
        "tick":{
            "trigger": "minecraft:tick"
        }
    },
    "rewards": {
        "function": "mydatapack:test"
    }
}

In that function set a block the player is in to powder snow, then revoke the Advancement. (My function makes sure it is only replacing air)

test.mcfunction

execute store success score #snow data run fill ~ ~1 ~ ~ ~1 ~ powder_snow replace air
execute if score #snow data matches 1 run summon marker ~ ~1 ~ {Tags:["snow"]}
advancement revoke @s only mydatapack:test

Then lastly in your datapack's tick function, set the powder snow back to air.

tick.mcfunction

execute at @e[tag=snow] run fill ~ ~ ~ ~ ~ ~ air replace powder_snow
kill @e[tag=snow]

Result help me

This isn't a simple solution, as technically you are walking around in a powder snow block. It is more effective to use this in an adventure map.

0

I also figured out another way that is potentially more limiting but also more elegant. My project is ice-themed and I wanted to have puzzles revolving around freezing, but there is not an easy way to do that. What I settled with, is using a resource pack! You can go into blockbench and make an infinitesimal point for a block model, and replace the powdered snow with said model. You can cover the entire floor of the area in powdered snow, and they get the freezing effect, however this means you cannot decorate the floor. Another thing I figured out in my extensive testing is that the white fog that appears when fully submerged in it, if you apply blindness to the player, it removes the fog. Take with that what you will. In just a resource pack, powdered snow can be completely invisible and you can freeze people to your heart's content.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .