tellraw @a[scores={me-debugging=1..}] "undeadmaelys-m1:potion/effect_do_gravitation" particle minecraft:dust 0.47058823 0.18433137 0.78039215 1 ~ ~1 ~ 0.30 0.5 0.30 0.5 1 force execute unless score @s me-core_shift matches 1.. run tag @s remove GravitySwitched execute if score @s me-core_shift matches 1.. run scoreboard players add @s me-m1_stimer 1 execute if score @s me-m1_stimer matches 1.. unless score @s me-core_shift matches 1.. run scoreboard players remove @s me-m1_stimer 1 execute if score @s me-m1_stimer matches 5.. run tag @s[tag=!GravitySwitched] add GravitySwitch execute if score @s me-m1_stimer matches 5.. run scoreboard players set @s me-m1_stimer 0 execute if score @s me-m1_stimer matches 5.. run tag @s add GravitySwitched execute if entity @s[tag=GravityReversed,tag=GravitySwitch] run function undeadm-m1:potion/effect_switch_gravitation execute if entity @s[tag=GravitySwitch] run tag @s add GravityReversed tag @s remove GravitySwitch execute as @s[tag=GravityReversed] run effect give @s[nbt={ActiveEffects:[{Id:28b}]}] minecraft:levitation 1 4 true execute as @s[tag=GravityReversed] unless entity @s[nbt={ActiveEffects:[{Id:28b}]}] run effect give @s minecraft:levitation 1 12 true