How to link to custom “archive like” page with custom permalink rules “dynamically”

Just write a function that checks if permalinks are on by checking whether get_option( 'permalink_structure' ) is empty or false and generates the appropriate link given the $id.

Something along the lines of the get_permalink() function which either looks at the $post global or looks at the $id passed into it.