mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-15 16:44:36 +00:00
Merge pull request #992 from Azaezel/alpha41/methodSig
better callback filtering for getMethodSigs
This commit is contained in:
commit
4489ebbf95
1 changed files with 11 additions and 4 deletions
|
|
@ -2662,7 +2662,7 @@ DefineEngineMethod( SimObject, dumpMethods, ArrayObject*, (),,
|
||||||
return dictionary;
|
return dictionary;
|
||||||
}
|
}
|
||||||
|
|
||||||
DefineEngineMethod(SimObject, getMethodSigs, ArrayObject*, (), ,
|
DefineEngineMethod(SimObject, getMethodSigs, ArrayObject*, (bool commands), (false),
|
||||||
"List the methods defined on this object.\n\n"
|
"List the methods defined on this object.\n\n"
|
||||||
"Each description is a newline-separated vector with the following elements:\n"
|
"Each description is a newline-separated vector with the following elements:\n"
|
||||||
"- method prototype string.\n"
|
"- method prototype string.\n"
|
||||||
|
|
@ -2682,9 +2682,16 @@ DefineEngineMethod(SimObject, getMethodSigs, ArrayObject*, (), ,
|
||||||
{
|
{
|
||||||
Namespace::Entry* e = *j;
|
Namespace::Entry* e = *j;
|
||||||
|
|
||||||
if (e->mType != Namespace::Entry::ScriptCallbackType)
|
if (commands)
|
||||||
continue;
|
{
|
||||||
|
if ((e->mType < Namespace::Entry::ConsoleFunctionType))
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if ((e->mType > Namespace::Entry::ScriptCallbackType))
|
||||||
|
continue;
|
||||||
|
}
|
||||||
StringBuilder str;
|
StringBuilder str;
|
||||||
str.append("function ");
|
str.append("function ");
|
||||||
str.append(ns->getName());
|
str.append(ns->getName());
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue