i am making a drawing with finger app.
I want to set a start point and end point.
My project is like this, it has a background that will tell you the direction to draw. when the user hits the end point the background will change.
i tried this…
On touches began…
drawPoint = [touch locationInView:self.view];
CGRect writingStartPoint = CGRectMake(90, 800, 30, 30);
CGRect writingEndPoint = CGRectMake(390, 800, 30, 30);
if (CGRectContainsPoint(writingStartPoint, drawPoint))
{
//something
}
if (CGRectContainsPoint(writingEndPoint, drawPoint))
{
//change background
}
it’s not working.
Is there another way?
you should check is touch in end rectangle on touch moved or ended method