ExplosionData: PlayerData: VehicleData
by Rex · in Torque Game Engine · 09/20/2007 (8:48 am) · 3 replies
I've been working with vehicles extesively lately and got a very nice effect from stock TGE working. It deals with onDestroyed state and debris and making the exploding object turn into flying bits of itself. It was very easy to setup [for an Artist] and wondered if someone with greater scripting/Code knowledge could hep me out, extending this functionality to the playerData.
What I achieved was that when any vehicle in question transitions to onDestroyed state[going beyond maxDamage], the debris.dts I constructed and pointed to, renders as flying debris of the explosion. This was totally unexpected. What I 'expected' to see was a beat-up hull left over after the explosion, sitting on the ground[in one single piece]; what I got was a very dynamic object[s]!!! What I got was ALL the parts of my object[debris.dts], flying in all directions!!! That was cool. I'm fairly certain it is how I setup the ART for the dts....I'm willing to share the secret, with a fair exchange of scripting help to get this working with the Player datablock....it was very easy with the vehicle code I was hacking....assignment here, path there...POOF, it all worked in like 15 minutes. Again, this was an Artist scripting/hacking here...;).
From stock tge, the debrisShapeName assignment is there[DTS shape], but it goes cold after that, no assignment to a DebriData datablock or otherwise...no explosion emitters or particles...seems a lot of the pieces are there, just need to be assembled in the right flow. What a very nice stock effect to demonstrate...?? I think.
Any scripters out there in the 'know' about this stock TGE effect? I saw this once in TribesII...I was piloting a flying vehicle and it exploded in the pieces I describe and I seem to remember my playerAvatar doing the same??? It would be really great to see this in TGE stock, working...
Thanks.
What I achieved was that when any vehicle in question transitions to onDestroyed state[going beyond maxDamage], the debris.dts I constructed and pointed to, renders as flying debris of the explosion. This was totally unexpected. What I 'expected' to see was a beat-up hull left over after the explosion, sitting on the ground[in one single piece]; what I got was a very dynamic object[s]!!! What I got was ALL the parts of my object[debris.dts], flying in all directions!!! That was cool. I'm fairly certain it is how I setup the ART for the dts....I'm willing to share the secret, with a fair exchange of scripting help to get this working with the Player datablock....it was very easy with the vehicle code I was hacking....assignment here, path there...POOF, it all worked in like 15 minutes. Again, this was an Artist scripting/hacking here...;).
From stock tge, the debrisShapeName assignment is there[DTS shape], but it goes cold after that, no assignment to a DebriData datablock or otherwise...no explosion emitters or particles...seems a lot of the pieces are there, just need to be assembled in the right flow. What a very nice stock effect to demonstrate...?? I think.
Any scripters out there in the 'know' about this stock TGE effect? I saw this once in TribesII...I was piloting a flying vehicle and it exploded in the pieces I describe and I seem to remember my playerAvatar doing the same??? It would be really great to see this in TGE stock, working...
Thanks.
About the author
Rex does all his 3D graphics through BrokeAssGames and is currently working on DSQTweaker, Ecstasy Motion, and other interesting projects yet to be revealed. Just ask him about anything DTS/DSQ related, he's happy to help.
#2
yea, if you can, please link to where in TDN it demonstrates how to get multiple debris objects from a single dts object and it's setup!....I don't really need an entire game example for some scripting pointers, ;). Thank you.
09/20/2007 (10:39 am)
Good ole TDN....somewhere? I was looking at the vehicle setups and some seemed outdated?! I'll have to check around there again, don't look much anymore. I guess look under debris. Interesting stuf, very cool how it 'destroyed' my singleObject shape into multiple parts, be nice to see it as Community knowledge or pointed to....I knew I'd seen it workng default much earlier.yea, if you can, please link to where in TDN it demonstrates how to get multiple debris objects from a single dts object and it's setup!....I don't really need an entire game example for some scripting pointers, ;). Thank you.
#3
But it's definitely around, in TDN or in the forums, can't remember right now precisely.
09/20/2007 (12:35 pm)
Uhm, sorry, it's a long time ago since I searched for that topics and honestly I don't have at hand the links right here (and it's not to sell the FGE! :-)But it's definitely around, in TDN or in the forums, can't remember right now precisely.
Torque Owner Martin Schultz