Author Topic: Objects in TorqueScript  (Read 1263 times)

    I was wondering how would you find out which objects classes are built into TorqueScript and how you would find what methods and properties they have built into them.  Also what would be the best way of finding out what their parent classes they belong to and what child classes they have if any.

dumpConsoleClasses() gives you a list of every class type and its functions. Note that GUI objects (if you're running non-dedi) and individual datablocks count as class types and show up there too.

Thanks I'll look into that

One more question while I'm thinking about it.
How are datablock objects different from regular objects, the way I understood it is that Datablocks are objects that the client can see like a interior instance, terrain block, gui element, ect, is this right or am I confused.
« Last Edit: February 23, 2009, 05:34:49 PM by adc90 »

A datablock transmitted to clients gives information about an object type so it can be created more quickly. Instead of sending "create a projectile with this shape and this emitter and this damage type and this life time" to clients, you can just send "create a gunProjectile" and then it'll automatically be handled. There is a limit of 2048 datablocks to prevent too much loading on joining a server. This load could be completely eliminated but it'd end up causing more transmitting and therefore more lag throughout the entire server creating objects instead of a one-time load.

A datablock transmitted to clients gives information about an object type so it can be created more quickly. Instead of sending "create a projectile with this shape and this emitter and this damage type and this life time" to clients, you can just send "create a gunProjectile" and then it'll automatically be handled. There is a limit of 2048 datablocks to prevent too much loading on joining a server. This load could be completely eliminated but it'd end up causing more transmitting and therefore more lag throughout the entire server creating objects instead of a one-time load.

That makes sense, thanks for your help  :cookie: