creating an id system to keep track of who owns an area effect cloud to tp the owner to

As the title says I'm making an id system to keep track of which player owns which aec and then when a thing happens they get teleported to it. If it wasn't clear yet, this is a multiplayer datapack so I want to be able to handle multiple players.

The id is being handled through a dummy scoreboard

Right now I have an id of 1 that is set to the player when the aec gets created and then applying the id to the aec to match the player that caused it to be summoned when the player gets with a radius I have set up.

Every tick any entity that has an id of 1 or higher gets their number added by 1.

Then the execute command to detect the teleport is set up to first find the player with a matching id of the aec, then it detects if that player is within a radius around the protected area, and then runs the tp. This has yet to be tested, hopefully I'll get to tomorrow. But I think I'll encounter a problem teleporting the player to the correct aec since the tp is just a tp @e[tag=specialtptag,limit=1]

Then when the game no longer detects this specific aec with the tag it clears the id from everyone.

I really don't think this will work. How could I improve this?

Continue to help post