aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--graphics/sjis.cpp3
-rw-r--r--graphics/sjis.h4
2 files changed, 6 insertions, 1 deletions
diff --git a/graphics/sjis.cpp b/graphics/sjis.cpp
index 4dd24d9dcc..facf0470b2 100644
--- a/graphics/sjis.cpp
+++ b/graphics/sjis.cpp
@@ -537,7 +537,8 @@ bool FontSjisSVM::loadData() {
}
uint32 version = data->readUint32BE();
- if (version != 3) {
+ if (version != kSjisFontVersion) {
+ warning("SJIS font version mismatch, expected: %d found: %u", kSjisFontVersion, version);
delete data;
return false;
}
diff --git a/graphics/sjis.h b/graphics/sjis.h
index 185b6cc593..f96eef6ad1 100644
--- a/graphics/sjis.h
+++ b/graphics/sjis.h
@@ -263,6 +263,10 @@ private:
const uint8 *getCharDataDefault(uint16 c) const;
void mapKANJIChar(const uint8 fB, const uint8 sB, int &base, int &index) const;
+
+ enum {
+ kSjisFontVersion = 3
+ };
};
// TODO: Consider adding support for PC98 ROM