mirror of
https://github.com/kichikuou/system3-sdl2.git
synced 2026-10-04 12:58:01 +03:00
Refectoring: Add is_[12]byte_message() helper functions
This commit is contained in:
@@ -798,8 +798,7 @@ void NACT_Sys3::cmd_m()
|
||||
int d, p = 0;
|
||||
|
||||
while((d = getd()) != ':') {
|
||||
if((0x81 <= d && d <= 0x9f) || 0xe0 <= d) {
|
||||
// 2bytes
|
||||
if(is_2byte_message(d)) {
|
||||
string[p++] = d;
|
||||
string[p++] = getd();
|
||||
} else {
|
||||
@@ -1385,7 +1384,7 @@ void NACT_Sys3::cmd_y()
|
||||
} else {
|
||||
uint8 code = tvar[param - 1][s++];
|
||||
string[d++] = code;
|
||||
if((0x81 <= code && code <= 0x9f) || 0xe0 <= code) {
|
||||
if(is_2byte_message(code)) {
|
||||
string[d++] = tvar[param - 1][s++];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user