text: If the target permanent became an illegal target by the time Dire-Strain Rampage tried to resolve, the spell won't resolve and none of its effects will happen. No player will search their library for any cards. However, if the target is still legal but wasn't destroyed, perhaps because it was indestructible, its controller may still search their library for a basic land card (even if the target was a land).