X-Git-Url: https://git.yukkurigames.com/?p=enjoyable.git;a=blobdiff_plain;f=JSAction.m;h=0cb98554bf020ba58c622924533e9da9ebadf23e;hp=84d1ea84c395d40587dd3bd04879fc74247fa51c;hb=25dd74a4a34f4ba7ec797360bd8f92cbd7bc758e;hpb=20ccd38576bb48caf8e4129a8c86fe04819d83bc diff --git a/JSAction.m b/JSAction.m index 84d1ea8..0cb9855 100644 --- a/JSAction.m +++ b/JSAction.m @@ -14,22 +14,30 @@ @synthesize children; @synthesize base; @synthesize name; +@synthesize active; + +- (id)initWithName:(NSString *)newName base:(JSAction *)newBase { + if ((self = [super init])) { + self.name = newName; + self.base = newBase; + } + return self; +} - (id)findSubActionForValue:(IOHIDValueRef)value { return NULL; } -- (NSString *)stringify { - return [NSString stringWithFormat: @"%@~%p", [base stringify], cookie]; +- (NSString *)uid { + return [NSString stringWithFormat:@"%@~%@", [self.base uid], self.name]; } - (void)notifyEvent:(IOHIDValueRef)value { [self doesNotRecognizeSelector:_cmd]; } -- (BOOL)active { - [self doesNotRecognizeSelector:_cmd]; - return NO; +- (float)magnitude { + return 0.f; } @end