Thanks for the comments
. Yes the explosions are are way too heavy on the CPU, also because all barrels explode in a chain reaction. I've been fiddling a lot with the params, but I guess making good explosions is quite an expertise.
These are the emitter params:
Code:
<Emitter name="ParticleSystem1" material="barrel/explosion1.material.xml" particleEffect="barrel/explosion1.particle.xml"
maxCount="50" respawnCount="1" delay="0" emissionRate="200" spreadAngle="360"
forceX="0" forceY="0" forceZ="0" />
<ParticleEffect lifeMin="1" lifeMax="2.0">
<ChannelOverLife channel="moveVel" startMin="4.0" startMax="8.0" endRate="2" />
<ChannelOverLife channel="rotVel" startMin="10" startMax="210" endRate="0.57" />
<ChannelOverLife channel="size" startMin="6" startMax="9" endRate="4" />
<ChannelOverLife channel="colR" startMin="0.4" startMax="0.6" endRate="0.0" />
<ChannelOverLife channel="colG" startMin="0.2" startMax="0.3" endRate="0.0" />
<ChannelOverLife channel="colB" startMin="0.1" startMax="0.2" endRate="0.0" />
<ChannelOverLife channel="colA" startMin="0.1" startMax="0.2" endRate="0.0" />
</ParticleEffect>
<Emitter name="ParticleSystem2" material="barrel/explosion2.material.xml" particleEffect="barrel/explosion2.particle.xml"
maxCount="50" respawnCount="1" delay="0.1" emissionRate="100" spreadAngle="360"
forceX="0" forceY="0.5" forceZ="0" />
<ParticleEffect lifeMin="1" lifeMax="4.0">
<ChannelOverLife channel="moveVel" startMin="4.0" startMax="6.0" endRate="0" />
<ChannelOverLife channel="rotVel" startMin="1" startMax="2" endRate="0.57" />
<ChannelOverLife channel="size" startMin="4" startMax="2" endRate="4" />
<ChannelOverLife channel="colR" startMin="1" startMax="1" endRate="0.0" />
<ChannelOverLife channel="colG" startMin="1" startMax="1" endRate="0.0" />
<ChannelOverLife channel="colB" startMin="1" startMax="1" endRate="0.0" />
<ChannelOverLife channel="colA" startMin="-0.1" startMax="0" endRate="0" />
</ParticleEffect>
There is great particle middleware out there. Maybe creating an extension for one would be a good idea.
The decals are parallax shaded meshes with a small offset from the surface they lay on. Also a semi transparent shader will make them appear to match colors on all materials. They're not perfect and shooting several decals over each other will cause z-fighting.