Is it possible to do something like this?
if (myVariable == 100 for more than 1 second) {
}
So if myVariable equals 100 for more than 1 second do something.
Thanks!
Elijah
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You could start an NSTimer from within the body of the if() statement that has a timer of 1 second. So something like
If you get the timer to call a method that then does what you want.
This should work but I can’t help but feel there is a better solution to the actual problem your trying to solve.