aoc-2015/jour14/raindeer.h

27 lines
643 B
C
Raw Normal View History

2021-03-25 18:35:10 +01:00
#import <Foundation/Foundation.h>
@interface Raindeer : NSObject
{
NSString *name;
int speed;
int boostTime;
int pause;
2021-03-26 16:53:45 +01:00
int points;
int cooldown;
int hypervitesse;
int distance;
2021-03-25 18:35:10 +01:00
}
// permet de générer des setters et getter selon des attributs
// ici retain, nonatomic et assign
@property (retain, nonatomic) NSString *name;
2021-03-26 16:53:45 +01:00
@property (assign) int speed, boostTime, pause, points, cooldown, hypervitesse, distance;
2021-03-25 18:35:10 +01:00
+ (id) initWithName:(NSString*)name zatSpeed:(int)speed boostTime:(int)timeSpeed LunchTime:(int)pause;
- (int) calculDistance:(int)time;
2021-03-30 01:49:26 +02:00
- (void) updateDistance;
2021-03-26 16:53:45 +01:00
- (void) updatePoints;
2021-03-25 18:35:10 +01:00
@end