X-Git-Url: https://git.yukkurigames.com/?p=enjoyable.git;a=blobdiff_plain;f=Target.h;h=93b181f083acbc820e1496d0d4955485b2190057;hp=43b7d0c10fa3a345c657afadecf70f1a45d08f6e;hb=dd1f684886c2809133356bb9b335a35293e8849e;hpb=61f8cdec21ab083b29c22aa11fda54d6005666ca diff --git a/Target.h b/Target.h index 43b7d0c..93b181f 100644 --- a/Target.h +++ b/Target.h @@ -6,21 +6,21 @@ // Copyright 2009 University of Otago. All rights reserved. // -#import +@class JoystickController; -@interface Target : NSObject { - BOOL running; - BOOL isContinuous; - double inputValue; -} +@interface Target : NSObject -@property(readwrite) BOOL running; -@property(readonly) BOOL isContinuous; -@property(readwrite) double inputValue; --(void) trigger: (JoystickController *)jc; --(void) untrigger: (JoystickController *)jc; --(void) update: (JoystickController *)jc; --(NSString*) stringify; -+(Target*) unstringify: (NSString*) str withConfigList: (NSArray*) configs; +@property (assign) float magnitude; +@property (assign) BOOL running; +@property (readonly) BOOL isContinuous; + +- (void)trigger; +- (void)untrigger; +- (BOOL)update:(JoystickController *)jc; + +- (NSDictionary *)serialize; ++ (Target *)targetDeserialize:(NSDictionary *)serialization + withConfigs:(NSArray *)configs; ++ (NSString *)serializationCode; @end