TX3D | T3D | Torque Core | GMK | Scene Level | Mission Level | Torque Script | C# | XNA
by Patrick Force · in Torque X 3D · 02/03/2010 (9:27 am) · 10 replies
I am starting to actually code my game..and still trying to use TX3D builder like T3D World Editor.
As I look through both the FPS in TX3D and the DataBlocks in T3D, I have a couple questions..
Because all are included in my game..TX3D | T3D | Torque Core
what truly is the crossover matrix??
I see all the T3D Components that are referenced in both TX3D and T3D..
Data Blocks/Particle Definitions/materials/but actually using or calling them is a little different / one is C# T3D, and and the other TX3D, is through both C# and TorqueScript read/write as XML (level editor).
Has any one worked with both and figured out what will really go in/out of both..easily..
I know about the physical assets and file types dts,seq,triggers all seamless...
datablock conversion??
Has anyone tried to create/convert/automate large multiple level scenes in TX# and TX3D??
-------------------------------------------------------------------------------------------
Here is my latest TX Tool video??...
I will post the second part soon..the code actually running in the TX3D engine..
www.youtube.com/watch?v=4Mynax5GCko
Comments??
As I look through both the FPS in TX3D and the DataBlocks in T3D, I have a couple questions..
Because all are included in my game..TX3D | T3D | Torque Core
what truly is the crossover matrix??
I see all the T3D Components that are referenced in both TX3D and T3D..
Data Blocks/Particle Definitions/materials/but actually using or calling them is a little different / one is C# T3D, and and the other TX3D, is through both C# and TorqueScript read/write as XML (level editor).
Has any one worked with both and figured out what will really go in/out of both..easily..
I know about the physical assets and file types dts,seq,triggers all seamless...
datablock conversion??
Has anyone tried to create/convert/automate large multiple level scenes in TX# and TX3D??
-------------------------------------------------------------------------------------------
Here is my latest TX Tool video??...
I will post the second part soon..the code actually running in the TX3D engine..
www.youtube.com/watch?v=4Mynax5GCko
Comments??
About the author
Using tools like Maya, MotionBuilder, ZBrush, Photoshop, MS Visual Studio, rapidly delivering custom solutions, where only your imagination is the limit.
#2
basic torque script, called both w/ scene and .cs.
as in the fps demo
ie..
Description of GMK Object’s Templates -> Player Template:
base values "wrapped" in code that each engine can then understand..
I will create a video of what I am talking about..creating a full scene in T3D..
going back to that T3D Directory..and extract(Parse/Insert Unique Values) the code the was generated from my new mission file..as well as all the torque script that was generated with the GMK (DataBlocks)..then piece by peice..come up w/ a successfull transfer matrix look up table.
Mission Level File: Sub call on Datablock Player.cs:
datablock Debris -> TX3D LookUp Table -> Yes/No
datablock DebrisData( PlayerDebris )
{
explodeOnMaxBounce = false;
if "N"o then swith to a Paticle Effect or 2d Sprite for TX3D..all automated through multiple dimensional arrays and loops.
I have most of the the core TX3D public delegates that are really T3D based already in a working 25 table fully indexed database.
thats how I am able to parse large scenes from .fbx ascii..
TX3D------------------
<RigidComponent type="GarageGames.Torque.T3D.T3DRigidComponent">
and from the Game Mech Kit:
__________________________
Physics Objects (Rigid Bodies, Soft Bodies*)
Datablock fields:
shapeFile – filename of the dts model.
scale – vector for the shape.
mass – a mass of the object in kilograms.
Fields that allow user to add physics collision shape to the object
ie:
new RigidBody(PhysBarrel03) {
dataBlock = "PhysBarrel";
position = "519.137 686.943 256.635";
rotation = "-0.0225523 -0.0138033 0.99965 4.87245";
scale = "1 1 1";
canSaveDynamicFields = "1";
Enabled = "1";
category = "Physics";
editorIcon = "tools/LogickingEditor/images/Physics";
templateName = "PhysBarrel";
};
02/04/2010 (4:30 am)
I do not think your understanding me...basic torque script, called both w/ scene and .cs.
as in the fps demo
ie..
Description of GMK Object’s Templates -> Player Template:
base values "wrapped" in code that each engine can then understand..
I will create a video of what I am talking about..creating a full scene in T3D..
going back to that T3D Directory..and extract(Parse/Insert Unique Values) the code the was generated from my new mission file..as well as all the torque script that was generated with the GMK (DataBlocks)..then piece by peice..come up w/ a successfull transfer matrix look up table.
Mission Level File: Sub call on Datablock Player.cs:
datablock Debris -> TX3D LookUp Table -> Yes/No
datablock DebrisData( PlayerDebris )
{
explodeOnMaxBounce = false;
if "N"o then swith to a Paticle Effect or 2d Sprite for TX3D..all automated through multiple dimensional arrays and loops.
I have most of the the core TX3D public delegates that are really T3D based already in a working 25 table fully indexed database.
thats how I am able to parse large scenes from .fbx ascii..
TX3D------------------
<RigidComponent type="GarageGames.Torque.T3D.T3DRigidComponent">
and from the Game Mech Kit:
__________________________
Physics Objects (Rigid Bodies, Soft Bodies*)
Datablock fields:
shapeFile – filename of the dts model.
scale – vector for the shape.
mass – a mass of the object in kilograms.
Fields that allow user to add physics collision shape to the object
ie:
new RigidBody(PhysBarrel03) {
dataBlock = "PhysBarrel";
position = "519.137 686.943 256.635";
rotation = "-0.0225523 -0.0138033 0.99965 4.87245";
scale = "1 1 1";
canSaveDynamicFields = "1";
Enabled = "1";
category = "Physics";
editorIcon = "tools/LogickingEditor/images/Physics";
templateName = "PhysBarrel";
};
#3
<[dbValue] type="[dbValue] " name="[dbValue] ">
<NameMapping>[dbValue] </NameMapping>
<TextureFilename>[dbValue] </TextureFilename>
<NormalMapFilename>[dbValue] </NormalMapFilename>
<SpecularPower>[dbValue] /SpecularPower>
<SpecularIntensity>[dbValue] </SpecularIntensity>
<LightingMode>[[dbValue]</LightingMode>
</[dbValue] >
02/04/2010 (4:34 am)
this is an example of how i can get shape/position/scale/materials from...fbx ascii /txtscene / mis files...and "wrap those values inany form I want:<[dbValue] type="[dbValue] " name="[dbValue] ">
<NameMapping>[dbValue] </NameMapping>
<TextureFilename>[dbValue] </TextureFilename>
<NormalMapFilename>[dbValue] </NormalMapFilename>
<SpecularPower>[dbValue] /SpecularPower>
<SpecularIntensity>[dbValue] </SpecularIntensity>
<LightingMode>[[dbValue]</LightingMode>
</[dbValue] >
#4
02/04/2010 (5:11 am)
Are you saying you wrote a program that converts Torque3D script to TX3D C# code?
#5
Perhaps there is some way you can figure out to convert the datablocks into XML that will work for TX3D, I know that is way more than I would do, I'd probably just slog through doing it by hand.
02/04/2010 (7:29 am)
The only things you can bring over from T3D, TGEA, TGE whatever right now are DTS models and DSQ animations. If you wrote any TorqueScript you will have to rewrite the functionality in C# in a component or some class. You cannot even bring over the terrains as the terrains changed at some point and you will need TGEA 1.5 or 1.4 to create a terrain. Perhaps there is some way you can figure out to convert the datablocks into XML that will work for TX3D, I know that is way more than I would do, I'd probably just slog through doing it by hand.
#6
all in the level editor...just look..I mean really look at the fps sample..and the .cs files..that basically run your game logic in T3D, from that..I took john's book..whick is all is mostly c# ..before the builder loads the xml..thats why I could't see my terrain in builder..but showed up fine in xna.. and moved all the 3d code/samples/fps..into a web based database application, that will also convert your fbx ascii to TorqueScript...
a good example is the Player Template. what I am working on now..with my $60.00 super app..ultimate unwrap 3d pro..converts ..pretty much anything to anything..w animations, dts seq..mount points..animated dts/.x..etc,..so now I can use ACK characters, everything except T3D terrains..from downtown/wharehouse/sticks N twigs..all running through TX3D, scene level data managed, organized, and created through data driven web pages...all assets, organize through a top down hierarchy..by scene group name.
That what I used to do..systems automation..
this is an early video..right after I got the entire city block, from downtown pack, to parse and build my 53 materials and torque script...in 1 minute..
www.forcevfx.com/GameBuilder/
there is one common thread..T3D and torque script..xna is just a shell
I am still in development..piece by peice..but it works and will allow me to dual devolop, and dual deploy..using the same assets/core code values, and tools from both!!
This is a Torque3D player DataBlock Particle definitions..
//----------------------------------------------------------------------------
// Splash
//----------------------------------------------------------------------------
datablock ParticleData(PlayerSplashMist)
{
dragCoefficient = 2.0;
gravityCoefficient = -0.05;
inheritedVelFactor = 0.0;
constantAcceleration = 0.0;
lifetimeMS = 400;
lifetimeVarianceMS = 100;
useInvAlpha = false;
spinRandomMin = -90.0;
spinRandomMax = 500.0;
textureName = "art/shapes/actors/common/splash";
colors[0] = "0.7 0.8 1.0 1.0";
colors[1] = "0.7 0.8 1.0 0.5";
colors[2] = "0.7 0.8 1.0 0.0";
sizes[0] = 0.5;
sizes[1] = 0.5;
sizes[2] = 0.8;
times[0] = 0.0;
times[1] = 0.5;
times[2] = 1.0;
};
datablock ParticleEmitterData(PlayerSplashMistEmitter)
{
ejectionPeriodMS = 5;
periodVarianceMS = 0;
ejectionVelocity = 3.0;
velocityVariance = 2.0;
ejectionOffset = 0.0;
thetaMin = 85;
thetaMax = 85;
phiReferenceVel = 0;
phiVariance = 360;
overrideAdvance = false;
lifetimeMS = 250;
particles = "PlayerSplashMist";
};
This is the Player script in TorqueX3D
<PlasmaParticleMaterial type="GarageGames.Torque.Materials.SimpleMaterial" name="PlasmaParticleMaterial">
<TextureFilename>data\images\plasma1</TextureFilename>
<IsTranslucent>true</IsTranslucent>
<IsAdditive>true</IsAdditive>
<IsColorBlended>true</IsColorBlended>
</PlasmaParticleMaterial>
<ParticleEmitter type="GarageGames.Torque.T3D.T3DParticleEmitter">
<UseLocalTransform>true</UseLocalTransform>
<ParticleEmitterData type="GarageGames.Torque.T3D.T3DParticleEmitterData">
<EjectionPeriodMS>15</EjectionPeriodMS>
<EjectionVelocity>-7</EjectionVelocity>
<VelocityVariance>0</VelocityVariance>
<EjectionOffset>1.2</EjectionOffset>
<ThetaMin>150</ThetaMin>
<ThetaMax>180</ThetaMax>.........
Take out the Field Names and the values store them separately.
now you can use datablocks in TorqueX3D...automaticly server side..
so parse scenee level data to mission level and back, to c# sub's??
its just a matter of time...
02/04/2010 (5:08 pm)
yes...it all comes over!!all in the level editor...just look..I mean really look at the fps sample..and the .cs files..that basically run your game logic in T3D, from that..I took john's book..whick is all is mostly c# ..before the builder loads the xml..thats why I could't see my terrain in builder..but showed up fine in xna.. and moved all the 3d code/samples/fps..into a web based database application, that will also convert your fbx ascii to TorqueScript...
a good example is the Player Template. what I am working on now..with my $60.00 super app..ultimate unwrap 3d pro..converts ..pretty much anything to anything..w animations, dts seq..mount points..animated dts/.x..etc,..so now I can use ACK characters, everything except T3D terrains..from downtown/wharehouse/sticks N twigs..all running through TX3D, scene level data managed, organized, and created through data driven web pages...all assets, organize through a top down hierarchy..by scene group name.
That what I used to do..systems automation..
this is an early video..right after I got the entire city block, from downtown pack, to parse and build my 53 materials and torque script...in 1 minute..
www.forcevfx.com/GameBuilder/
there is one common thread..T3D and torque script..xna is just a shell
I am still in development..piece by peice..but it works and will allow me to dual devolop, and dual deploy..using the same assets/core code values, and tools from both!!
This is a Torque3D player DataBlock Particle definitions..
//----------------------------------------------------------------------------
// Splash
//----------------------------------------------------------------------------
datablock ParticleData(PlayerSplashMist)
{
dragCoefficient = 2.0;
gravityCoefficient = -0.05;
inheritedVelFactor = 0.0;
constantAcceleration = 0.0;
lifetimeMS = 400;
lifetimeVarianceMS = 100;
useInvAlpha = false;
spinRandomMin = -90.0;
spinRandomMax = 500.0;
textureName = "art/shapes/actors/common/splash";
colors[0] = "0.7 0.8 1.0 1.0";
colors[1] = "0.7 0.8 1.0 0.5";
colors[2] = "0.7 0.8 1.0 0.0";
sizes[0] = 0.5;
sizes[1] = 0.5;
sizes[2] = 0.8;
times[0] = 0.0;
times[1] = 0.5;
times[2] = 1.0;
};
datablock ParticleEmitterData(PlayerSplashMistEmitter)
{
ejectionPeriodMS = 5;
periodVarianceMS = 0;
ejectionVelocity = 3.0;
velocityVariance = 2.0;
ejectionOffset = 0.0;
thetaMin = 85;
thetaMax = 85;
phiReferenceVel = 0;
phiVariance = 360;
overrideAdvance = false;
lifetimeMS = 250;
particles = "PlayerSplashMist";
};
This is the Player script in TorqueX3D
<PlasmaParticleMaterial type="GarageGames.Torque.Materials.SimpleMaterial" name="PlasmaParticleMaterial">
<TextureFilename>data\images\plasma1</TextureFilename>
<IsTranslucent>true</IsTranslucent>
<IsAdditive>true</IsAdditive>
<IsColorBlended>true</IsColorBlended>
</PlasmaParticleMaterial>
<ParticleEmitter type="GarageGames.Torque.T3D.T3DParticleEmitter">
<UseLocalTransform>true</UseLocalTransform>
<ParticleEmitterData type="GarageGames.Torque.T3D.T3DParticleEmitterData">
<EjectionPeriodMS>15</EjectionPeriodMS>
<EjectionVelocity>-7</EjectionVelocity>
<VelocityVariance>0</VelocityVariance>
<EjectionOffset>1.2</EjectionOffset>
<ThetaMin>150</ThetaMin>
<ThetaMax>180</ThetaMax>.........
Take out the Field Names and the values store them separately.
now you can use datablocks in TorqueX3D...automaticly server side..
so parse scenee level data to mission level and back, to c# sub's??
its just a matter of time...
#7
motioncapture.forcevfx.com/
so how else can I build an open world 3d fps in torquex in 30 days??..by myself??
I have the art, animations, story, particles, music, sound effects, now to just make it smart..using all the pre-built T3D components..already there..just call them in code once, deploy everywher..
all stored in Your Local Torque Master Database that Synchs to The Server Torque MDB..do you see...
I can not believe this has not been done in one way or the other.
It is so clear to me..I just feel dumb even talking aboutthis..like some kinda of newb question..But..I am right, it works..
I will, after my DBP entry..show and share with you..how you can get back to the real deal...just concentrate on "custom" coding your game.....
Truly Build Re-usable game Templates..based upon the core structure of torque..
02/04/2010 (5:49 pm)
keep in mind..i built this in 3 months..motioncapture.forcevfx.com/
so how else can I build an open world 3d fps in torquex in 30 days??..by myself??
I have the art, animations, story, particles, music, sound effects, now to just make it smart..using all the pre-built T3D components..already there..just call them in code once, deploy everywher..
all stored in Your Local Torque Master Database that Synchs to The Server Torque MDB..do you see...
I can not believe this has not been done in one way or the other.
It is so clear to me..I just feel dumb even talking aboutthis..like some kinda of newb question..But..I am right, it works..
I will, after my DBP entry..show and share with you..how you can get back to the real deal...just concentrate on "custom" coding your game.....
Truly Build Re-usable game Templates..based upon the core structure of torque..
#8
Torque Owner Henry -
would you like to wager something on this statment???
02/04/2010 (5:58 pm)
The only things you can bring over from T3D, TGEA, TGE whatever right now are DTS models and DSQ animations.Torque Owner Henry -
would you like to wager something on this statment???
#10
a quick convert to fbx..and you can auto-script into an engine..
loop, loopy, loopy doo!
______________________________
Here is my latest TX Tool video??...
I will post the second part soon..the code actually running in the TX3D engine..
www.youtube.com/watch?v=4Mynax5GCko
Comments??
02/05/2010 (5:02 pm)
sample fbx parse..dosn't matter if your model is..and your using 'dts'.a quick convert to fbx..and you can auto-script into an engine..
loop, loopy, loopy doo!
______________________________
Here is my latest TX Tool video??...
I will post the second part soon..the code actually running in the TX3D engine..
www.youtube.com/watch?v=4Mynax5GCko
Comments??
Torque Owner Trent
There are no datablocks in TX3D. TX3D is based of TGEA not T3D. TX3D is based around a component architecture, TGEA and T3D are still inheritance based and they are also designed around networking. There is no networking in TX3D. Essentially, TX3D has nothing to do with T3D, and although both were based of TGEA, they're too different to try and use them the same way.