Game Development Community

TorqueScript - dynamically getting a list of functions

by Johan Janssen · in Torque Game Engine · 03/24/2007 (6:03 am) · 1 replies

Is there a way to get a list of functions that can be called in a TorqueScript? Much like Reflection in C#.
I want to write a small unit testing framework for TS and want to generate a list of functions that are prefixed with "test" so that I can call them without having to register them.

#1
03/24/2007 (11:11 am)
In console:
dumpConsoleFunctions and dumpConsoleClasses might do the trick for you. You can modify it in consoledoc.cc to fit your needs and get it to some string into the script.