Letting wordpress decide what template and page to use based on condition

I’m not sure this is a great way, but for now that’s what I have:

  1. Set the front page setting in WordPress to posts and not static page, so WordPress will use the index.php file.

  2. In the index.php file write:

if (something) {
    global $post;
    $post = get_post( "the post id" );
    setup_postdata( $post );
    include('page-template-file.php');
}
else {
    global $post;
    $post = get_post( "the other post id" );
    setup_postdata( $post );
    include('page-other-template-file.php');
}

Note: you have to deal other pages with singular.php template and so… otherwise with this solution you will load one of this pages for any page on your site.