Now i have a function called CheckSensor, and when i put this anywhere in my main loop it doesn't run it anymore..
I uploaded the updated code
So, now we can compare your current code to your previous code, to see what you changed, right?DO NOT DO THAT AGAIN!!!!
I can't say i'm a programmer so i don't know how you guys work.