Skip to content

Instantly share code, notes, and snippets.

@alexplaskett
Created July 15, 2021 10:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alexplaskett/3eddf37d2a9b8a3b41d0f1e43a3a2ed9 to your computer and use it in GitHub Desktop.
Save alexplaskett/3eddf37d2a9b8a3b41d0f1e43a3a2ed9 to your computer and use it in GitHub Desktop.
ExpWnfFindStateName
_QWORD *__fastcall ExpWnfFindStateName(__int64 scopeinstance, unsigned __int64 statename)
{
_QWORD *i; // rax
for ( i = *(_QWORD **)(scopeinstance + 0x38); ; i = (_QWORD *)i[1] )
{
while ( 1 )
{
if ( !i )
return 0i64;
if ( statename >= i[3] )
break;
i = (_QWORD *)*i;
}
if ( statename <= i[3] )
break;
}
return i - 2;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment