X-Git-Url: https://git.yukkurigames.com/?p=enjoyable.git;a=blobdiff_plain;f=Target.h;h=df3535b7176b8c35973f008b5e6d07a4e536268f;hp=51470bfcd7f089f18945725f0c6cc2b7315e041b;hb=19f40be5b645e44ffb55bdce0b6cc5c5615f68e7;hpb=724979785b445dcba8a9861c2531ae0308bdf40a diff --git a/Target.h b/Target.h index 51470bf..df3535b 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; +@property (nonatomic, assign) float magnitude; +@property (nonatomic, assign) BOOL running; +@property (nonatomic, readonly) BOOL isContinuous; + +- (void)trigger; +- (void)untrigger; - (BOOL)update:(JoystickController *)jc; --(NSString*) stringify; -+(Target*) unstringify: (NSString*) str withConfigList: (NSArray*) configs; + +- (NSDictionary *)serialize; ++ (Target *)targetDeserialize:(NSDictionary *)serialization + withConfigs:(NSArray *)configs; ++ (NSString *)serializationCode; @end