X-Git-Url: https://git.yukkurigames.com/?p=enjoyable.git;a=blobdiff_plain;f=Target.m;h=ec2d6a16462c5b5f1701f97143e45ff017d5ee9b;hp=35ebfc2dfef16c8bb0189c518987657c6a045c15;hb=61f8cdec21ab083b29c22aa11fda54d6005666ca;hpb=ac4ed3987b6aaefc836294f89ff1f569fad6ac6b diff --git a/Target.m b/Target.m index 35ebfc2..ec2d6a1 100644 --- a/Target.m +++ b/Target.m @@ -19,6 +19,10 @@ return [TargetMouseMove unstringifyImpl:components]; if([typeTag isEqualToString:@"mbtn"]) return [TargetMouseBtn unstringifyImpl:components]; + if([typeTag isEqualToString:@"mscroll"]) + return [TargetMouseScroll unstringifyImpl:components]; + if([typeTag isEqualToString:@"mtoggle"]) + return [TargetToggleMouseScope unstringifyImpl:components]; NSParameterAssert(NO); return NULL; @@ -29,27 +33,22 @@ return NULL; } --(void) trigger { +-(void) trigger: (JoystickController *)jc { [self doesNotRecognizeSelector:_cmd]; } --(void) untrigger { +-(void) untrigger: (JoystickController *)jc { // no-op by default } --(BOOL) running { - return running; +-(void) update: (JoystickController *) jc { + [self doesNotRecognizeSelector:_cmd]; } --(void) setRunning: (BOOL) newRunning { - if(newRunning == running) - return; - if(newRunning) - [self trigger]; - else - [self untrigger]; - running = newRunning; + +-(BOOL) isContinuous { + return false; } -@synthesize inputValue; +@synthesize inputValue, running; @end