Console macros
by Danny Wyatt · in Torque Game Engine · 03/08/2006 (12:43 pm) · 1 replies
I understand how macros work in C++ so my issue is not with understanding macros. It specifically deals with the information supplied to them and what each piece information means.
I want to do the following:
ConsoleMethod(GACapture, {function name}, void, {minArg} , { maxArg }, {usage})
{
....do stuff here........
}
I understand why you supply the first 3, but what do the last 3 do:
(1) Do they specify how many parameters the { function name } accepts when calling it on the torque script side?
(2) Are minArg (and maxArg ) indices-type values (ie. 0, 1, 2,....) or are they totals-type values?
(a) if for example, I wrote a generic console method below:
ConsoleMethod(GACapture, Bark, void, 2, 3, "int count");
...what does the minArg, maxArg, usage mean????
my thoughts are that....
Arg 0 = "this" object passed in
Arg 1 = argc
Arg 2 = argv
....but I'm probably wrong. Any help would greatly appreciated : - )
I want to do the following:
ConsoleMethod(GACapture, {function name}, void, {minArg} , { maxArg }, {usage})
{
....do stuff here........
}
I understand why you supply the first 3, but what do the last 3 do:
(1) Do they specify how many parameters the { function name } accepts when calling it on the torque script side?
(2) Are minArg (and maxArg ) indices-type values (ie. 0, 1, 2,....) or are they totals-type values?
(a) if for example, I wrote a generic console method below:
ConsoleMethod(GACapture, Bark, void, 2, 3, "int count");
...what does the minArg, maxArg, usage mean????
my thoughts are that....
Arg 0 = "this" object passed in
Arg 1 = argc
Arg 2 = argv
....but I'm probably wrong. Any help would greatly appreciated : - )
About the author
Torque Owner Danny Wyatt