C++ Interfacing with TorqueScript
by Rivage · in Torque Game Builder · 02/21/2009 (6:07 am) · 1 replies
Hi
In order to use the Box2D wrapper from Michael Woerister I need to write part of my game in C++. Mainly because there is a lot of Contact Point Callback in this physic engine and Torquescript won't probably be fast enough to handle that.
My main problem is that as soon as I am in C++ side : I'm completely lost.
1) Does working in C++ is using exactly the same TorqueScript commands ?
2) If yes : Most of the generated Doxygen engine API is undocumented... Will I need something more than TorqueScript commands to write C++ interfacing class (as roughly explain in the TorqueScript Quick Reference page 3).
3) In order to manipulate Object created in TorqueScript side is there something more I should know except from Con::executef() ? (Like type or scoop restrictions...).
4) I would greatly appreciate if someone could write an example that cover :
- A C++ Class exposed to TGB TorqueScript
- A TGB Torquescript Object created in Runtime and Interfacing with C++
- A TorqueScript Object Method call from C++ Side
- How to locate TorqueScript Object from C++ Side
Thanks
In order to use the Box2D wrapper from Michael Woerister I need to write part of my game in C++. Mainly because there is a lot of Contact Point Callback in this physic engine and Torquescript won't probably be fast enough to handle that.
My main problem is that as soon as I am in C++ side : I'm completely lost.
1) Does working in C++ is using exactly the same TorqueScript commands ?
2) If yes : Most of the generated Doxygen engine API is undocumented... Will I need something more than TorqueScript commands to write C++ interfacing class (as roughly explain in the TorqueScript Quick Reference page 3).
3) In order to manipulate Object created in TorqueScript side is there something more I should know except from Con::executef() ? (Like type or scoop restrictions...).
4) I would greatly appreciate if someone could write an example that cover :
- A C++ Class exposed to TGB TorqueScript
- A TGB Torquescript Object created in Runtime and Interfacing with C++
- A TorqueScript Object Method call from C++ Side
- How to locate TorqueScript Object from C++ Side
Thanks
About the author
Leadwerks
Torque Owner Rivage
tools\docGenerator crash my XP in a very strange way (like MBR or partition corruption).
I was only having this running and MSVC9.0 with T2D open in debug mode I ran generateDocs.bat or something just after the build.
Now 90% of my files are missing (and most of the system32 files).
I try everything from Kubuntu to hiren's boot tools but nothing work anymore. Not even a TestDisk...
No program were install since 2 weeks so I'm nearly sure the problem came from TGB Pro tools.
Obviously very disappointed, I will have to reinstall my whole system.
I think I'm done with TGB until this engine do what I am waiting for out of the box. Probably never...