bfgStrings Class
Big Fish String class. More...
#import <bfgStrings.h>
Class Methods | |
(NSString *) | + stringFromKey: |
(NSString *) | + stringFromKey:forLanguage: |
(BOOL) | + loadStringFile: |
(BOOL) | + loadStringFile:fromString: |
Detailed Description
Big Fish String class. A localizable string class that enables a single file to store strings for all the languages supported by the game.
Method Documentation
◆ loadStringFile:
+ (BOOL) loadStringFile: | (NSString *) | filename |
- Parameters
filename A bfgstrings file.
- Returns
- Return values
YES if the file loaded without error. NO if the file did not load.
◆ loadStringFile:fromString:
+ (BOOL) loadStringFile: | (NSString *) | name | |
fromString: | (NSString *) | jsonText | |
- Parameters
name A namespace for the string values. jsonText A text JSON representation of a strings file.
- Returns
- YES if jsonText deserializes properly into dictionary.
- Return values
YES if jsonText deserializes properly into the dictionary. NO if jsonText does not deserialize into the dictionary.
◆ stringFromKey:
+ (NSString *) stringFromKey: | (NSString *) | key |
- Parameters
key A key in the bfgstrings file.
- Returns
- String for the key in the local language.
◆ stringFromKey:forLanguage:
+ (NSString *) stringFromKey: | (NSString *) | key | |
forLanguage: | (NSString *) | language | |
- Parameters
key A key in the bfgstrings file. language Two letter language code.
- Returns
- String for the key in the specified language.