Skip to content

Commit

Permalink
Fix missed cases of effect Id change to an int
Browse files Browse the repository at this point in the history
  • Loading branch information
misode committed Oct 13, 2023
1 parent d321d8b commit 82c9839
Show file tree
Hide file tree
Showing 12 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ execute store result entity @e[type=marker,tag=gm4_ta_pos_tracker,limit=1] Pos[1
execute store result entity @e[type=marker,tag=gm4_ta_pos_tracker,limit=1] Pos[2] double 0.01 run scoreboard players get @s gm4_ta_pos_z

execute at @e[type=marker,tag=gm4_ta_pos_tracker,limit=1] run tag @s[distance=5.8..] add gm4_ta_teleported
execute if entity @s[tag=gm4_ta_teleported] at @e[type=marker,tag=gm4_ta_pos_tracker,limit=1] run tag @s[type=enderman,distance=5.8..7.2,nbt={ActiveEffects:[{Id:1b,Amplifier:0b}]}] remove gm4_ta_teleported
execute if entity @s[tag=gm4_ta_teleported] at @e[type=marker,tag=gm4_ta_pos_tracker,limit=1] run tag @s[type=enderman,distance=5.8..10.1,nbt={ActiveEffects:[{Id:1b,Amplifier:1b}]}] remove gm4_ta_teleported
execute if entity @s[tag=gm4_ta_teleported] at @e[type=marker,tag=gm4_ta_pos_tracker,limit=1] run tag @s[type=enderman,distance=5.8..7.2,nbt={ActiveEffects:[{Id:1,Amplifier:0b}]}] remove gm4_ta_teleported
execute if entity @s[tag=gm4_ta_teleported] at @e[type=marker,tag=gm4_ta_pos_tracker,limit=1] run tag @s[type=enderman,distance=5.8..10.1,nbt={ActiveEffects:[{Id:1,Amplifier:1b}]}] remove gm4_ta_teleported

kill @e[type=marker,tag=gm4_ta_pos_tracker,limit=1]
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ execute if score difference gm4_ta_pos_x matches ..0 run scoreboard players oper

# mark entity as teleported if they moved too far
execute if entity @s[type=enderman] if score difference gm4_ta_pos_x matches 360.. run tag @s add gm4_ta_teleported
execute if score difference gm4_ta_pos_x matches 360..510 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1b,Amplifier:0b}]}] remove gm4_ta_teleported
execute if score difference gm4_ta_pos_x matches 360..690 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1b,Amplifier:1b}]}] remove gm4_ta_teleported
execute if score difference gm4_ta_pos_x matches 360..510 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1,Amplifier:0b}]}] remove gm4_ta_teleported
execute if score difference gm4_ta_pos_x matches 360..690 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1,Amplifier:1b}]}] remove gm4_ta_teleported

execute if entity @s[type=shulker] if score difference gm4_ta_pos_x matches 90.. run tag @s add gm4_ta_teleported
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ execute if score difference gm4_ta_pos_z matches ..0 run scoreboard players oper

# mark entity as teleported if they moved too far
execute if entity @s[type=enderman] if score difference gm4_ta_pos_z matches 360.. run tag @s add gm4_ta_teleported
execute if score difference gm4_ta_pos_z matches 360..510 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1b,Amplifier:0b}]}] remove gm4_ta_teleported
execute if score difference gm4_ta_pos_z matches 360..690 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1b,Amplifier:1b}]}] remove gm4_ta_teleported
execute if score difference gm4_ta_pos_z matches 360..510 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1,Amplifier:0b}]}] remove gm4_ta_teleported
execute if score difference gm4_ta_pos_z matches 360..690 run tag @s[type=enderman,nbt={ActiveEffects:[{Id:1,Amplifier:1b}]}] remove gm4_ta_teleported

execute if entity @s[type=shulker] if score difference gm4_ta_pos_z matches 90.. run tag @s add gm4_ta_teleported
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ execute store result score fall gm4_ta_pos_y run data get entity @s FallDistance
execute if score fall gm4_ta_pos_y matches 0..90 run tag @s add gm4_ta_teleported
execute if score fall gm4_ta_pos_y matches 91.. run tag @s add gm4_ta_falling

execute if entity @s[type=enderman,tag=gm4_ta_teleported,nbt={ActiveEffects:[{Id:1b,Amplifier:0b}]}] if score difference gm4_ta_pos_x matches 410..510 run tag @s remove gm4_ta_teleported
execute if entity @s[type=enderman,tag=gm4_ta_teleported,nbt={ActiveEffects:[{Id:1b,Amplifier:1b}]}] if score difference gm4_ta_pos_x matches 410..690 run tag @s remove gm4_ta_teleported
execute if entity @s[type=enderman,tag=gm4_ta_teleported,nbt={ActiveEffects:[{Id:1,Amplifier:0b}]}] if score difference gm4_ta_pos_x matches 410..510 run tag @s remove gm4_ta_teleported
execute if entity @s[type=enderman,tag=gm4_ta_teleported,nbt={ActiveEffects:[{Id:1,Amplifier:1b}]}] if score difference gm4_ta_pos_x matches 410..690 run tag @s remove gm4_ta_teleported
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"booze\",CustomPotionEffects:[{Id:2b,Amplifier:0b,Duration:1200},{Id:5b,Amplifier:0b,Duration:1200},{Id:9b,Amplifier:1b,Duration:400},{Id:19b,Amplifier:0b,Duration:400},{Id:22b,Amplifier:1b,Duration:1200}],CustomPotionColor:11236936}"
"tag": "{custom_potion:\"booze\",CustomPotionEffects:[{Id:2,Amplifier:0b,Duration:1200},{Id:5,Amplifier:0b,Duration:1200},{Id:9,Amplifier:1b,Duration:400},{Id:19,Amplifier:0b,Duration:400},{Id:22,Amplifier:1b,Duration:1200}],CustomPotionColor:11236936}"
},
{
"function": "set_name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"booze\",CustomPotionEffects:[{Id:2b,Amplifier:0b,Duration:300},{Id:5b,Amplifier:0b,Duration:300},{Id:9b,Amplifier:1b,Duration:100},{Id:19b,Amplifier:0b,Duration:100},{Id:22b,Amplifier:1b,Duration:300}],CustomPotionColor:11236936}"
"tag": "{custom_potion:\"booze\",CustomPotionEffects:[{Id:2,Amplifier:0b,Duration:300},{Id:5,Amplifier:0b,Duration:300},{Id:9,Amplifier:1b,Duration:100},{Id:19,Amplifier:0b,Duration:100},{Id:22,Amplifier:1b,Duration:300}],CustomPotionColor:11236936}"
},
{
"function": "set_name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"resistance\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:11b,Amplifier:0b,Duration:150}]}"
"tag": "{custom_potion:\"resistance\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:11,Amplifier:0b,Duration:150}]}"
},
{
"function": "set_name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"resistance\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:11b,Amplifier:0b,Duration:600}]}"
"tag": "{custom_potion:\"resistance\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:11,Amplifier:0b,Duration:600}]}"
},
{
"function": "set_name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"booze\",CustomPotionEffects:[{Id:2b,Amplifier:0b,Duration:1200},{Id:5b,Amplifier:0b,Duration:1200},{Id:9b,Amplifier:1b,Duration:400},{Id:19b,Amplifier:0b,Duration:400},{Id:22b,Amplifier:1b,Duration:1200}],CustomPotionColor:11236936}"
"tag": "{custom_potion:\"booze\",CustomPotionEffects:[{Id:2,Amplifier:0b,Duration:1200},{Id:5,Amplifier:0b,Duration:1200},{Id:9,Amplifier:1b,Duration:400},{Id:19,Amplifier:0b,Duration:400},{Id:22,Amplifier:1b,Duration:1200}],CustomPotionColor:11236936}"
},
{
"function": "set_name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"resistance\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:11b,Amplifier:0b,Duration:600}]}"
"tag": "{custom_potion:\"resistance\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:11,Amplifier:0b,Duration:600}]}"
},
{
"function": "set_name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"vanishing\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:14b,Amplifier:9b,Duration:600}]}"
"tag": "{custom_potion:\"vanishing\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:14,Amplifier:9b,Duration:600}]}"
},
{
"function": "set_name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
{
"function": "set_nbt",
"tag": "{custom_potion:\"vanishing\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:14b,Amplifier:9b,Duration:600}]}"
"tag": "{custom_potion:\"vanishing\",Potion:\"minecraft:mundane\",CustomPotionEffects:[{Id:14,Amplifier:9b,Duration:600}]}"
},
{
"function": "set_name",
Expand Down

0 comments on commit 82c9839

Please sign in to comment.