Script::getThreadName: Difference between revisions
(yay) |
No edit summary |
||
| Line 13: | Line 13: | ||
{{Script_s_function_c}} | {{Script_s_function_c}} | ||
[[Category:Clientside API]] | [[Category:Clientside API]] | ||
[[Category:Script API]] | |||
[[Category:TODO: Example]] | [[Category:TODO: Example]] | ||
Latest revision as of 21:25, 11 May 2017
The reversed code looks like this (Sasuke78200)
//
char g_szScriptName[64];
char* _0xBE7ACD89(int a_iThreadID)
{
scrThread* l_pThread;
// Get the script thread
l_pThread = GetThreadByID(a_iThreadID);
if(l_pThread == 0 || l_pThread->m_iThreadState == 2)
{
strncpy(g_szScriptName, , 64);
}
else
{
strncpy(g_szScriptName, l_pThread->m_szScriptName, 64);
}
return g_szScriptName;
}
Syntax
mp.game.script.getThreadName(threadId);
Required Arguments
- threadId: int
Return value
- String
Example
// todo