Oolite 1.91.0.7645-241119-222d325
Loading...
Searching...
No Matches
OOCharacter.h
Go to the documentation of this file.
1/*
2
3OOCharacter.h
4
5Represents an NPC person (as opposed to an NPC ship).
6
7Oolite
8Copyright (C) 2004-2013 Giles C Williams and contributors
9
10This program is free software; you can redistribute it and/or
11modify it under the terms of the GNU General Public License
12as published by the Free Software Foundation; either version 2
13of the License, or (at your option) any later version.
14
15This program is distributed in the hope that it will be useful,
16but WITHOUT ANY WARRANTY; without even the implied warranty of
17MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18GNU General Public License for more details.
19
20You should have received a copy of the GNU General Public License
21along with this program; if not, write to the Free Software
22Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
23MA 02110-1301, USA.
24
25*/
26
27#import <Foundation/Foundation.h>
28#import "OOTypes.h"
29#import "legacy_random.h"
30#import "OOJSPropID.h"
31
32@class OOJSScript;
33
34
35@interface OOCharacter: NSObject
36{
37@private
38 NSString *_name;
46}
47
48- (id) initWithRole:(NSString *)role andOriginalSystem:(OOSystemID)s;
49
50+ (OOCharacter *) characterWithRole:(NSString *)c_role andOriginalSystem:(OOSystemID)s;
51+ (OOCharacter *) randomCharacterWithRole:(NSString *)c_role andOriginalSystem:(OOSystemID)s;
52+ (OOCharacter *) characterWithDictionary:(NSDictionary *)c_dict;
53
54- (NSString*) planetOfOrigin;
55- (OOSystemID) planetIDOfOrigin;
56- (NSString*) species;
57
58- (void) basicSetUp;
59- (BOOL) castInRole:(NSString *)role;
60
61- (NSString *) name;
62- (void) setName:(NSString *)value;
63
64- (NSString *) shortDescription;
65- (void) setShortDescription:(NSString *)value;
66
67- (int) legalStatus;
68- (void) setLegalStatus:(int)value;
69
70- (OOCreditsQuantity) insuranceCredits;
71- (void) setInsuranceCredits:(OOCreditsQuantity)value;
72
73- (NSArray *) legacyScript;
74- (void) setLegacyScript:(NSArray *)scriptActions;
75- (OOJSScript *)script;
76- (void) setCharacterScript:(NSString *)scriptName;
77- (void) doScriptEvent:(jsid)message;
78
79- (NSDictionary *) infoForScripting;
80
81@end
uint64_t OOCreditsQuantity
Definition OOTypes.h:182
int16_t OOSystemID
Definition OOTypes.h:211
NSString * _name
Definition OOCharacter.h:38
Random_Seed _genSeed
Definition OOCharacter.h:41
OOJSScript * _script
Definition OOCharacter.h:45
OOCreditsQuantity _insuranceCredits
Definition OOCharacter.h:43
OOSystemID _originSystem
Definition OOCharacter.h:40
NSArray * _scriptActions
Definition OOCharacter.h:44
NSString * _shortDescription
Definition OOCharacter.h:39
typedef int(ZCALLBACK *close_file_func) OF((voidpf opaque