2D texture application doesn't work in game build

I just found the solution for those who have the same problem go to your texture and scroll down a little bit and look for “Filter” and set it to “Nearest”