I have recreated this issue in several ways via datapacks doing the following:
create an enchantment that is triggering effects "minecraft:projectile_spawned"
type is set to "minecraft:run_function" and runs the following function
supported items can be a crossbow, or a bow
function triggered by effect is as follows:
execute as @s store result entity @s Motion[0] double 0.0002 run data get entity @s Motion[0] 10000
execute as @s store result entity @s Motion[1] double 0.0002 run data get entity @s Motion[1] 10000
execute as @s store result entity @s Motion[2] double 0.0002 run data get entity @s Motion[2] 10000
enchant crossbow or bow with enchant mentioned above
Function in Datapack under FOLDER/data/test_enchants/function/ench/crossbow_test
execute as @s store result entity @s Motion[0] double 0.0002 run data get entity @s Motion[0] 10000
execute as @s store result entity @s Motion[1] double 0.0002 run data get entity @s Motion[1] 10000
execute as @s store result entity @s Motion[2] double 0.0002 run data get entity @s Motion[2] 10000
additionally, in the function, if a schedule function (or a repeating command block targeting arrows in the air) is included to display a particle at the arrows location the particles would be updated every tick in the correct location, but the arrow trail and animation would still go off into incorrect direction.
I have also repeated using a 3 repeating command block that was targeting arrows without a "speed" tag to apply individual motion index modifiers for motion[0] motion[1] and motion[2]. each repeating command block also had a chain command block that would tag the arrow with the "speed" tag and similar results apply.
I have recreated this issue in several ways via datapacks doing the following:
create an enchantment that is triggering effects "minecraft:projectile_spawned"
type is set to "minecraft:run_function" and runs the following function
supported items can be a crossbow, or a bow
function triggered by effect is as follows:
enchant crossbow or bow with enchant mentioned above
charge and fire crossbow/bow
MY ENCHANT:
Function in Datapack under FOLDER/data/test_enchants/function/ench/crossbow_test
additionally, in the function, if a schedule function (or a repeating command block targeting arrows in the air) is included to display a particle at the arrows location the particles would be updated every tick in the correct location, but the arrow trail and animation would still go off into incorrect direction.
I have also repeated using a 3 repeating command block that was targeting arrows without a "speed" tag to apply individual motion index modifiers for motion[0] motion[1] and motion[2]. each repeating command block also had a chain command block that would tag the arrow with the "speed" tag and similar results apply.