binding 2 entities together?

so i have a custom minecart (block display riding minecart), and part of the mechanic is that the block shoots out when on activator rails right now im just copying over the nbt from the nearby-est minecart to it, which is sub optimal since it ends up not having motion when the minecart is too fast and shot away too quickly

data modify entity @n[type=falling_block,distance=..1] Motion set from entity @n[type=minecart,distance=..10] Motion

can i somehow pair them up so it copies over the motion from exactly the minecart it needs?

Continue to help post