advancement revoke @s only minecraft:suhc/piercingdamagecrossbow
advancement grant @s only minecraft:suhc/piercingdamagecrossbow2
#execute at @s run summon armor_stand ~ ~1 ~ {Tags:["SuperBloodBolt"],NoGravity:1b,Invulnerable:1b,Marker:1b,Invisible:1b,Silent:1b,Silent:1b}
#execute at @s run tp @e[type=armor_stand,limit=1,sort=nearest,tag=BloodBolt] ~ ~1 ~ ~ ~

execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run execute store result score @s KyuDummy run data get entity @s PierceLevel
############################################################################################################################dont mind me using PosX as a second dummy here
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run scoreboard players set @s PosX 15
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run scoreboard players operation @s PosX *= @s KyuDummy
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run scoreboard players add @s PosX 120
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run scoreboard players operation @s KyuDummy = @s PosX
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run data merge entity @s {PierceLevel:0b}

execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run execute store result score @s PosX run data get entity @s Motion[0] 10000
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run execute store result score @s PosY run data get entity @s Motion[1] 10000
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run execute store result score @s PosZ run data get entity @s Motion[2] 10000
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run scoreboard players operation @s PosX *= @s KyuDummy
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run scoreboard players operation @s PosY *= @s KyuDummy
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run scoreboard players operation @s PosZ *= @s KyuDummy
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run execute store result entity @s Motion[0] double .000001 run scoreboard players get @s PosX
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run execute store result entity @s Motion[1] double .000001 run scoreboard players get @s PosY
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run execute store result entity @s Motion[2] double .000001 run scoreboard players get @s PosZ
execute at @s positioned ~ ~1.5 ~ run execute as @e[type=arrow,limit=1,sort=nearest,distance=..1.5,nbt={life:0s},tag=!GotMot] run tag @s add GotMot

#kill @e[type=arrow,distance=..2]
#execute at @e[name=DayQ] run data merge block 999991 120 999979 {auto:1b}
#effect give @s wither 1 1
#effect give @s poison 1 1
#give @s emerald 1