Having regrets :(

So I had sex with one of my friend who I had for a long time we agreed we didn’t want to date each other just attracted to each other so we did so and I risked it me not being on the pill and only condoms... well the next day he’s already in a relationship with this girl he’s been talking to for awhile I guess .. and I wish I never did that with him and he was comparing features of us and I got insecure.