Skip to content

Commit

Permalink
SakuraScriptのタグ解釈修正
Browse files Browse the repository at this point in the history
コミット忘れてた これがほんとの Mc170-4
  • Loading branch information
ponapalt committed Oct 28, 2024
1 parent d3d56bc commit 9f6d39b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
4 changes: 2 additions & 2 deletions satoriya/satori/resource.rc
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,170,3,1
FILEVERSION 1,170,4,1
PRODUCTVERSION 1,0,0,1
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
Expand All @@ -47,7 +47,7 @@ BEGIN
VALUE "Comments", " \0"
VALUE "CompanyName", " \0"
VALUE "FileDescription", "satori\0"
VALUE "FileVersion", "1, 170, 3, 1\0"
VALUE "FileVersion", "1, 170, 4, 1\0"
VALUE "InternalName", "satori\0"
VALUE "LegalCopyright", " \0"
VALUE "LegalTrademarks", "\0"
Expand Down
2 changes: 1 addition & 1 deletion satoriya/satori/satori.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const char* gSatoriName = "Satori";
const char* gSatoriNameW = "里々";
const char* gSatoriCraftman = "Yagi Kushigahama/The Maintenance Shop";
const char* gSatoriCraftmanW = "櫛ヶ浜やぎ/整備班";
const char* gSatoriVersion = "phase Mc170-3";
const char* gSatoriVersion = "phase Mc170-4";
const char* gShioriVersion = "3.0";
const char* gSaoriVersion = "1.0";

Expand Down
12 changes: 10 additions & 2 deletions satoriya/satori/satori_sentence.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -490,10 +490,18 @@ int Satori::SentenceToSakuraScriptInternal(const strvec &vec,string &result,stri
string cmd="",opt="";

//複数個のアンダースコアと、1個の文字
while (!_ismbblead(*p) && *p=='_')
while (!_ismbblead(*p) && *p=='_') {
++p;
if (!_ismbblead(*p) && (isalpha(*p)||isdigit(*p)||*p=='!'||*p=='-'||*p=='*'||*p=='&'||*p=='?'||*p=='+'))
}
if (!_ismbblead(*p) && (isalpha(*p)||isdigit(*p)||*p=='!'||*p=='-'||*p=='*'||*p=='&'||*p=='?'||*p=='+')) {
char c = *p;
++p;
if (!_ismbblead(*p) && (c == 'w' || c == 's' || c == 'p')) {
if ( isdigit(*p) ) {
++p;
}
}
}
cmd.assign(start, p-start);

if ( cmd == "_?" || cmd == "_!" ) { //エスケープ処理 この間に自動タグ挿入はしない
Expand Down

0 comments on commit 9f6d39b

Please sign in to comment.