Time complexity of this algorithm

I’m using some code to find the minimum distance to a point in the graph. I have no clue whether it’s bfs or dfs or djistkra’s and I’m not able to figure out the time complexity. Is it too slow and will I have to learn some other algorithm because i just put this in all graph distance problems but there are many 0.00 sec answers. It basically starts at node 0, and checks where it can go. Then it checks where it can go and adds it to the check vector and removes the 0. Then it goes through one of the points, the last one it found, and apply the same logic as when start was 0. The nodes get put in tochk again if a faster route is found.