Seems like I switched variables names half way through in my example and forgot to execute the query
It should be:
$statement = $mysqli->prepare('SELECT ip FROM `unbanned` WHERE ip=?');
$statement->bind_param("s", $ip);
$statement->execute();
$statement->bind_result($selectedIp);
$statement->fetch();