remove this if (level == 100)  (have only else) 
then it will work same as above. Now value 99 gives nothing