more stable character filter
This commit is contained in:
parent
d9e4998119
commit
45bf759aa5
@ -6354,15 +6354,15 @@ static bool InsertYuris2Hook()
|
||||
|
||||
static bool Yuris3Filter(LPVOID data, DWORD *size, HookParam *, BYTE)
|
||||
{
|
||||
static bool bEven = false;
|
||||
static wchar_t even_text;
|
||||
static wchar_t prev_text;
|
||||
wchar_t* pText = reinterpret_cast<wchar_t*>(data);
|
||||
|
||||
if (bEven = !bEven)
|
||||
even_text = *pText;
|
||||
else
|
||||
if (even_text == *pText)
|
||||
return false;
|
||||
if (prev_text == *pText)
|
||||
{
|
||||
prev_text = '\0';
|
||||
return false;
|
||||
}
|
||||
prev_text = *pText;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user