I've found the example code to be very helpful, it's great to have a really good example like this thanks for all your efforts.
on line ~283 $example_link doesn't return the full domain unless the user is logged in. when logged out the base screen-one and screen-two example doesn't work and you end up with a recursive series of links:
$example_link = trailingslashit( bp_loggedin_user_domain() . bp_get_example_slug() );
I think perhaps it should be:
$example_link = trailingslashit( bp_displayed_user_domain() . bp_get_example_slug() );