I'm trying to call the touchesBegan, touchesMoved, and touchesEnded methods from one class(called MainLine) in my ViewController class. I created my object
Code:
MainLine *mainline = [[MainLine alloc] init];
and then tried to call to MainLine in
Code:
-(void)callingMethod {
[mainline touchesBegan:touches withEvent:event];
[mainline touchesMoved:touches withEvent:event];
[mainline touchesEnded:touches withEvent:event];
}
and it did not work. Yet, it works perfectly fine when I run the entire methods in the ViewController. Any help?