Game Development Community

Footstep sounds, decals and puffs in TGEA 1.8.1.

by BrokeAss Games · in Torque Game Engine Advanced · 02/25/2009 (3:18 pm) · 3 replies

I'm pretty new to 1.8.1 (aren't we all) and I couldn't find any info on this, but I was pretty sure propertyMaps weren't used anymore.
After looking in the engine I realized it's now part of the material and has been expanded a little.
Basically in your materials.cs when you define a material you add these:
showFootprints =true;
    showDust = true;
    effectColor = "0.46 0.36 0.26 0.4 0.0";
    footstepSoundId = 1;
    impactSoundId = 1;
    //customImpactSound = "scriptsandassets/data/sounds/custom_mono.ogg";
    //customFootstepSound = "scriptsandassets/data/sounds/custom_mono.ogg";

so your material should look something like this:

new Material(bproad02)
{
    mapTo = "bproad02";
    baseTex[0] = "bproad02";
    bumpTex[0] = "bproad02_NRM";
    pixelSpecular[0] = true;
    specular[0] = "1 1 1 1";
    specularPower[0] = 16.0;
    //FootSteps and Impact    
    footstepSoundId = 1;
    //customFootstepSound = "scriptsandassets/data/sounds/custom_mono.ogg";
    impactSoundId = 1;
    //customImpactSound = "scriptsandassets/data/sounds/custom_mono.ogg";
    showFootprints =true;
    showDust = true;
    effectColor = "0.46 0.36 0.26 0.4 0.0";
};
and that works great as long as your animations have triggers.

My question is this, how would I get this to work on Atlas?
What would be the texture I map to and do I need to add an Atlas object type in the engine?
Is it that easy?

Ari

#1
03/02/2009 (10:41 am)
*Bump*

Starting to lean towards MegaTerrains...
#2
03/24/2009 (1:24 pm)
\GameExamples\T3D\game\scriptsAndAssets\data\terrains\Test\materials.cs has all the answers to my questions.
It was there the whole time.
#3
03/24/2009 (4:24 pm)
That's the way it always is.