linking a player with another entity

the goal is to move data from a player to an entity and vice versa; which i've achieved but the end result is extremely laggy i started by giving both the player and the entity a player.id score unique to the 2 of them, then running: execute at @s as @a[] if score @s player.id = @n[tag=ride] player.id run function sinoan:test/main @s in this case is @e[tag=ride] this then runs the function main which contains 12ish commands similar to this one execute if predicate sinoan:forward_pressed at @s as @e[tag=ride] if score @s player.id = @a[limit=1] player.id run function sinoan:test/direction/forward my question was if itd be possible to shrink down the selectors (which are 100% causing the lag) or if there's just a straight up better method to achieve this
Continue to help post