Added tile check and fixed % number