Creating a particle effect in code. [resolved]
by Cosmic Logic · in Torque Game Builder · 05/13/2009 (11:05 pm) · 3 replies
Hey,
I apoligise if this has been answered before, but without the search function on the forums finding anything is way too time consuming.
I'm trying to make and mount a particle effect in code.
Here is what I have:
I get nothing with that. I've also tried this to just put it in the center of the screen.
I've also tried it without using the %county, just having new t2dParticleEffect.. etc.
Not sure what I'm doing wrong here, if anyone could point me in the right direction that would be great.
I apoligise if this has been answered before, but without the search function on the forums finding anything is way too time consuming.
I'm trying to make and mount a particle effect in code.
Here is what I have:
%county = new t2dParticleEffect(whee) {
effectFile = "~/data/particles/superShotCount.eff";
useEffectCollisions = "0";
effectMode = "KILL";
effectTime = "9.5";
size = "10 10";
CollisionMaxIterations = "1";
};
%county.mount(%this.owner, 1,0,0,true,true,true,true);I get nothing with that. I've also tried this to just put it in the center of the screen.
%county = new t2dParticleEffect(whee) {
effectFile = "~/data/particles/superShotCount.eff";
useEffectCollisions = "0";
effectMode = "KILL";
effectTime = "9.5";
position = "0 0";
size = "10 10";
CollisionMaxIterations = "1";
};I've also tried it without using the %county, just having new t2dParticleEffect.. etc.
Not sure what I'm doing wrong here, if anyone could point me in the right direction that would be great.
Torque 3D Owner Aun Taraseina
new t2dParticleEffect() { scenegraph = %this.owner.getSceneGraph(); // Add me! };