Oftentimes rocks are just in your way and act as obstacles, but after you clear a room, take your time and inspect the rocks. A rock featuring a small X indicates treasure inside—blow it up.